| @@ 465-473 (lines=9) @@ | ||
| 462 | $query['$readPreference'] = $v; |
|
| 463 | } |
|
| 464 | ||
| 465 | if (is_string($p['where'])) { |
|
| 466 | $query['where'] = new \MongoCode($p['where']); |
|
| 467 | } elseif (is_object($p['where']) || sizeof($p['where'])) { |
|
| 468 | $query['query'] = $p['where']; |
|
| 469 | } |
|
| 470 | $cb = CallbackWrapper::wrap($cb); |
|
| 471 | if ($this->safeMode) { |
|
| 472 | static::safeModeEnc($query); |
|
| 473 | } |
|
| 474 | try { |
|
| 475 | $this->request( |
|
| 476 | self::OP_QUERY, |
|
| @@ 734-742 (lines=9) @@ | ||
| 731 | $query['$max'] = $p['max']; |
|
| 732 | } |
|
| 733 | ||
| 734 | if (is_string($p['where'])) { |
|
| 735 | $query['where'] = new \MongoCode($p['where']); |
|
| 736 | } elseif (is_object($p['where']) || sizeof($p['where'])) { |
|
| 737 | $query['query'] = $p['where']; |
|
| 738 | } |
|
| 739 | ||
| 740 | $cb = CallbackWrapper::wrap($cb); |
|
| 741 | if ($this->safeMode) { |
|
| 742 | static::safeModeEnc($query); |
|
| 743 | } |
|
| 744 | try { |
|
| 745 | $this->request( |
|