Completed
Pull Request — master (#255)
by Andreas
21:00
created
lib/Mongo/MongoDBRef.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
      */
78 78
     public static function get($db, $ref)
79 79
     {
80
-        if (! static::isRef($ref)) {
80
+        if ( ! static::isRef($ref)) {
81 81
             return null;
82 82
         }
83 83
 
Please login to merge, or discard this patch.
lib/Mongo/MongoRegex.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
             return;
44 44
         }
45 45
 
46
-        if (! preg_match('#^/(.*)/([imxslu]*)$#', $regex, $matches)) {
46
+        if ( ! preg_match('#^/(.*)/([imxslu]*)$#', $regex, $matches)) {
47 47
             throw new MongoException('invalid regex', 9);
48 48
         }
49 49
 
Please login to merge, or discard this patch.
lib/Mongo/functions.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 
16 16
 use Alcaeus\MongoDbAdapter\TypeConverter;
17 17
 
18
-if (! function_exists('bson_decode')) {
18
+if ( ! function_exists('bson_decode')) {
19 19
     /**
20 20
      * Deserializes a BSON object into a PHP array
21 21
      *
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
     }
29 29
 }
30 30
 
31
-if (! function_exists('bson_encode')) {
31
+if ( ! function_exists('bson_encode')) {
32 32
     /**
33 33
      * Serializes a PHP variable into a BSON string
34 34
      *
Please login to merge, or discard this patch.
lib/Mongo/MongoId.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
     {
49 49
         if ($value instanceof ObjectID || $value instanceof MongoId) {
50 50
             return true;
51
-        } elseif (! is_string($value)) {
51
+        } elseif ( ! is_string($value)) {
52 52
             return false;
53 53
         }
54 54
 
Please login to merge, or discard this patch.
lib/Mongo/MongoCursor.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
      */
222 222
     public function hasNext()
223 223
     {
224
-        if (! $this->startedIterating) {
224
+        if ( ! $this->startedIterating) {
225 225
             $this->ensureIterator();
226 226
             $this->startedIterating = true;
227 227
             $this->storeIteratorState();
@@ -405,7 +405,7 @@  discard block
 block discarded – undo
405 405
      */
406 406
     protected function convertCursorType()
407 407
     {
408
-        if (! $this->tailable) {
408
+        if ( ! $this->tailable) {
409 409
             return null;
410 410
         }
411 411
 
@@ -446,7 +446,7 @@  discard block
 block discarded – undo
446 446
     protected function wrapTraversable(\Traversable $traversable)
447 447
     {
448 448
         foreach ($traversable as $key => $value) {
449
-            if (isset($value->_id) && ($value->_id instanceof \MongoDB\BSON\ObjectID || !is_object($value->_id))) {
449
+            if (isset($value->_id) && ($value->_id instanceof \MongoDB\BSON\ObjectID || ! is_object($value->_id))) {
450 450
                 $key = (string) $value->_id;
451 451
             }
452 452
             yield $key => $value;
Please login to merge, or discard this patch.
lib/Alcaeus/MongoDbAdapter/AbstractCursor.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
      */
161 161
     public function next()
162 162
     {
163
-        if (! $this->startedIterating) {
163
+        if ( ! $this->startedIterating) {
164 164
             $this->ensureIterator();
165 165
             $this->startedIterating = true;
166 166
         } else {
@@ -402,7 +402,7 @@  discard block
 block discarded – undo
402 402
      */
403 403
     protected function storeIteratorState()
404 404
     {
405
-        if (! $this->startedIterating) {
405
+        if ( ! $this->startedIterating) {
406 406
             $this->current = null;
407 407
             $this->key = null;
408 408
             $this->valid = false;
Please login to merge, or discard this patch.
lib/Alcaeus/MongoDbAdapter/Helper/WriteConcernConverter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
             $wstring = (int) $wstring;
30 30
         }
31 31
 
32
-        if (! is_string($wstring) && ! is_int($wstring)) {
32
+        if ( ! is_string($wstring) && ! is_int($wstring)) {
33 33
             trigger_error("w for WriteConcern must be a string or integer", E_USER_WARNING);
34 34
             return false;
35 35
         }
Please login to merge, or discard this patch.
lib/Mongo/MongoGridFSFile.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@
 block discarded – undo
78 78
             $filename = 'file';
79 79
         }
80 80
 
81
-        if (! $handle = fopen($filename, 'w')) {
81
+        if ( ! $handle = fopen($filename, 'w')) {
82 82
             trigger_error('Can not open the destination file', E_USER_ERROR);
83 83
             return 0;
84 84
         }
Please login to merge, or discard this patch.
lib/Alcaeus/MongoDbAdapter/Helper/ReadPreference.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -110,7 +110,7 @@
 block discarded – undo
110 110
                 return false;
111 111
         }
112 112
 
113
-        if ($readPreference == \MongoClient::RP_PRIMARY && !empty($tags)) {
113
+        if ($readPreference == \MongoClient::RP_PRIMARY && ! empty($tags)) {
114 114
             trigger_error("You can't use read preference tags with a read preference of PRIMARY", E_USER_WARNING);
115 115
             return false;
116 116
         }
Please login to merge, or discard this patch.