We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 51d54ab commit af0651cCopy full SHA for af0651c
src/functions.php
@@ -121,9 +121,7 @@ function document_to_array($document): array
121
'document' => 'bson',
122
'root' => 'array',
123
]);
124
- }
125
-
126
- if ($document instanceof Serializable) {
+ } elseif ($document instanceof Serializable) {
127
$document = $document->bsonSerialize();
128
}
129
@@ -244,9 +242,7 @@ function is_pipeline($pipeline): bool
244
242
245
243
246
247
248
249
- if ($pipeline instanceof Serializable) {
+ } elseif ($pipeline instanceof Serializable) {
250
$pipeline = $pipeline->bsonSerialize();
251
252
0 commit comments