Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-598

Indexing in Typed Update Builder Breaks with Variable

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.6.1
    • Affects Version/s: 1.6
    • Component/s: None
    • None

      static void Main()

      { int index = 10; var update = Update<TestClass>.Set(x => x.List[index].Name, "Blah"); Console.WriteLine(update.ToString()); }

      private class TestClass
      {
      public ObjectId Id

      { get; set; }

      public List<SubTestClass> List { get; set; }

      }

      private class SubTestClass
      {
      public string Name

      { get; set; }

      }

            Assignee:
            craig.wilson@mongodb.com Craig Wilson
            Reporter:
            craig.wilson@mongodb.com Craig Wilson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: