Completed
Push — master ( ec539d...346131 )
by Adrian
02:33 queued 11s
created
src/Manticoresearch/Query.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
     public function toArray()
15 15
     {
16 16
 
17
-       return  $this->_toArray($this->_params);
17
+        return  $this->_toArray($this->_params);
18 18
     }
19 19
 
20 20
     protected function _toArray($params)
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 {
9 9
     protected $_params;
10 10
 
11
-    public function add($k,$v) {
11
+    public function add($k, $v) {
12 12
         $this->_params[$k] = $v;
13 13
     }
14 14
     public function toArray()
@@ -26,9 +26,9 @@  discard block
 block discarded – undo
26 26
             } elseif (is_array($v)) {
27 27
                 $return[$k] = $this->_toArray($v);
28 28
             } else {
29
-                if($v!==null) {
29
+                if ($v !== null) {
30 30
                     $return[$k] = $v;
31
-                }else {
31
+                } else {
32 32
                     return null;
33 33
                 }
34 34
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
             } else {
29 29
                 if($v!==null) {
30 30
                     $return[$k] = $v;
31
-                }else {
31
+                } else {
32 32
                     return null;
33 33
                 }
34 34
 
Please login to merge, or discard this patch.
src/Manticoresearch/Query/Match.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
 {
11 11
     public function __construct($keywords, $fields)
12 12
     {
13
-        $this->_params['match'] =[$fields => $keywords];
13
+        $this->_params['match'] = [$fields => $keywords];
14 14
     }
15 15
 
16 16
 }
17 17
\ No newline at end of file
Please login to merge, or discard this patch.
src/Manticoresearch/Query/BoolQuery.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -10,17 +10,17 @@
 block discarded – undo
10 10
 {
11 11
     public function must($args):self
12 12
     {
13
-        $this->_params['must'][]= $args;
13
+        $this->_params['must'][] = $args;
14 14
         return $this;
15 15
     }
16 16
     public function mustNot($args):self
17 17
     {
18
-        $this->_params['must_not'][]= $args;
18
+        $this->_params['must_not'][] = $args;
19 19
         return $this;
20 20
     }
21 21
     public function should($args):self
22 22
     {
23
-        $this->_params['should'][]= $args;
23
+        $this->_params['should'][] = $args;
24 24
         return $this;
25 25
     }
26 26
     public function toArray()
Please login to merge, or discard this patch.
src/Manticoresearch/Query/Equals.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
 
9 9
 class Equals extends Query
10 10
 {
11
-    public function __construct($field,$args)
11
+    public function __construct($field, $args)
12 12
     {
13 13
         $this->_params['equals'] = [$field => $args];
14 14
     }
Please login to merge, or discard this patch.
src/Manticoresearch/Query/Range.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@
 block discarded – undo
8 8
 
9 9
 class Range extends Query
10 10
 {
11
-    public function __construct($field,$args=[])
11
+    public function __construct($field, $args = [])
12 12
     {
13 13
         $this->_params['range'] = [$field => $args];
14 14
     }
Please login to merge, or discard this patch.
src/Manticoresearch/Search.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
         $this->_query->must(new QueryString($string));
65 65
         return $this;
66 66
     }
67
-    public function match($keywords,$fields=null):self
67
+    public function match($keywords, $fields = null):self
68 68
     {
69 69
         $f = "*";
70 70
         if ($fields !== null && is_string($fields)) {
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
         $this->_query->must(new Match($keywords, $f));
74 74
         return $this;
75 75
     }
76
-    public function phrase($string,$fields=null):self
76
+    public function phrase($string, $fields = null):self
77 77
     {
78 78
         $f = "*";
79 79
         if ($fields !== null && is_string($fields)) {
Please login to merge, or discard this patch.
src/Manticoresearch/Index.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -118,12 +118,12 @@
 block discarded – undo
118 118
         return $this->_client->indices()->create($params);
119 119
     }
120 120
 
121
-    public function drop($silent=false)
121
+    public function drop($silent = false)
122 122
     {
123 123
         $params = [
124 124
             'index' => $this->_index,
125 125
         ];
126
-        if($silent===true) {
126
+        if ($silent === true) {
127 127
             $params['body'] = ['silent'=>true];
128 128
         }
129 129
         return $this->_client->indices()->drop($params);
Please login to merge, or discard this patch.