(
ns: MongoDBCollectionNamespace,
filter: Document,
update: Document,
options: UpdateOptions
)
| 128 | /** @internal */ |
| 129 | export class UpdateOneOperation extends UpdateOperation { |
| 130 | constructor( |
| 131 | ns: MongoDBCollectionNamespace, |
| 132 | filter: Document, |
| 133 | update: Document, |
| 134 | options: UpdateOptions |
| 135 | ) { |
| 136 | super(ns, [makeUpdateStatement(filter, update, { ...options, multi: false })], options); |
| 137 | |
| 138 | if (!hasAtomicOperators(update, options)) { |
| 139 | throw new MongoInvalidArgumentError(class="st">'Update document requires atomic operators'); |
| 140 | } |
| 141 | } |
| 142 | |
| 143 | override handleOk( |
| 144 | response: InstanceType<typeof this.SERVER_COMMAND_RESPONSE_TYPE> |
nothing calls this directly
no test coverage detected