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

Update variants allow sending empty documents as update statements, which results in a replacement

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 2.0.1, 2.1
    • 2.0
    • None
    • None

    Description

      This should not be legal due to the second argument being a replacement (i.e., no dollar operators exist.)

      await collection.UpdateOneAsync("{x:1}", "{ }");
      

      Attachments

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved: