|
27 | 27 | #include "phongo_error.h"
|
28 | 28 |
|
29 | 29 | #include "BSON/Document.h"
|
30 |
| -#include "MongoDB/Server.h" |
31 | 30 | #include "MongoDB/WriteConcernError.h"
|
32 | 31 | #include "MongoDB/WriteError.h"
|
33 | 32 | #include "BulkWriteCommandResult_arginfo.h"
|
@@ -192,21 +191,6 @@ static PHP_METHOD(MongoDB_Driver_BulkWriteCommandResult, getUpsertedCount)
|
192 | 191 | RETURN_LONG(intern->upserted_count);
|
193 | 192 | }
|
194 | 193 |
|
195 |
| -/* Returns the last Server used to execute a command for the bulk write */ |
196 |
| -static PHP_METHOD(MongoDB_Driver_BulkWriteCommandResult, getServer) |
197 |
| -{ |
198 |
| - php_phongo_bulkwritecommandresult_t* intern; |
199 |
| - |
200 |
| - intern = Z_BULKWRITECOMMANDRESULT_OBJ_P(getThis()); |
201 |
| - |
202 |
| - PHONGO_PARSE_PARAMETERS_NONE(); |
203 |
| - |
204 |
| - PHONGO_BULKWRITECOMMANDRESULT_CHECK_ACKNOWLEDGED("getServer"); |
205 |
| - |
206 |
| - // TODO: null handling |
207 |
| - phongo_server_init(return_value, &intern->manager, intern->server_id); |
208 |
| -} |
209 |
| - |
210 | 194 | static PHP_METHOD(MongoDB_Driver_BulkWriteCommandResult, getInsertResults)
|
211 | 195 | {
|
212 | 196 | php_phongo_bulkwritecommandresult_t* intern;
|
@@ -401,17 +385,6 @@ static HashTable* php_phongo_bulkwritecommandresult_get_debug_info(zend_object*
|
401 | 385 | ADD_ASSOC_NULL_EX(&retval, "errorReply");
|
402 | 386 | }
|
403 | 387 |
|
404 |
| - if (intern->server_id) { |
405 |
| - zval server; |
406 |
| - |
407 |
| - phongo_server_init(&server, &intern->manager, intern->server_id); |
408 |
| - ADD_ASSOC_ZVAL_EX(&retval, "server", &server); |
409 |
| - } else { |
410 |
| - /* TODO: Determine if this path is only reached when a partial result is |
411 |
| - * attached to a BulkWriteCommandException on an unacknowledged write. */ |
412 |
| - ADD_ASSOC_NULL_EX(&retval, "server"); |
413 |
| - } |
414 |
| - |
415 | 388 | return Z_ARRVAL(retval);
|
416 | 389 | }
|
417 | 390 |
|
@@ -451,8 +424,6 @@ php_phongo_bulkwritecommandresult_t* phongo_bulkwritecommandresult_init(zval* re
|
451 | 424 | bwcr->insert_results = _bson_copy_or_null(mongoc_bulkwriteresult_insertresults(bw_ret->res));
|
452 | 425 | bwcr->update_results = _bson_copy_or_null(mongoc_bulkwriteresult_updateresults(bw_ret->res));
|
453 | 426 | bwcr->delete_results = _bson_copy_or_null(mongoc_bulkwriteresult_deleteresults(bw_ret->res));
|
454 |
| - |
455 |
| - bwcr->server_id = mongoc_bulkwriteresult_serverid(bw_ret->res); |
456 | 427 | }
|
457 | 428 |
|
458 | 429 | // Copy mongoc_bulkwriteexception_t fields
|
|
0 commit comments