Skip to content

Commit b9bd6ee

Browse files
m-ghazanfarkevinAlbs
authored andcommitted
CXX-2028 fix writeConcern population in find_and_modify
1 parent 216b613 commit b9bd6ee

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/mongocxx/collection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ mongocxx::stdx::optional<bsoncxx::document::value> find_and_modify(
9191
if (!wc->is_acknowledged() && opts["collation"]) {
9292
throw mongocxx::logic_error{mongocxx::error_code::k_invalid_parameter};
9393
}
94-
opts_builder.append(concatenate(wc->to_document()));
94+
opts_builder.append(kvp("writeConcern", wc->to_document()));
9595
}
9696

9797
mongocxx::libbson::scoped_bson_t command_bson{command};

0 commit comments

Comments
 (0)