Completed
Pull Request — master (#29)
by Ozan
05:26
created
src/Contracts/Intl.php 3 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
     /**
22 22
      * Set the current locale.
23 23
      *
24
-     * @param $locale
24
+     * @param string $locale
25 25
      * @return $this
26 26
      */
27 27
     abstract public function setLocale($locale);
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
     /**
37 37
      * Set the fallback locale.
38 38
      *
39
-     * @param $locale
39
+     * @param string $locale
40 40
      * @return $this
41 41
      */
42 42
     abstract public function setFallbackLocale($locale);
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
     /**
55 55
      * Forget the search cache as whole or by key.
56 56
      *
57
-     * @return array
57
+     * @return Intl
58 58
      */
59 59
     public function forgetSearchCache($cacheKey = null)
60 60
     {
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -84,15 +84,15 @@  discard block
 block discarded – undo
84 84
 
85 85
         $results = $this->all();
86 86
 
87
-        $filterCallback = function ($name) use ($includeKeywords, $excludeKeywords) {
87
+        $filterCallback = function($name) use ($includeKeywords, $excludeKeywords) {
88 88
             $includeCondition = $excludeCondition = true;
89 89
 
90
-            if (! empty($includeKeywords)) {
91
-                $includeCondition = (bool) preg_match('/'.implode('|', $includeKeywords).'/', $name);
90
+            if (!empty($includeKeywords)) {
91
+                $includeCondition = (bool) preg_match('/' . implode('|', $includeKeywords) . '/', $name);
92 92
             }
93 93
 
94
-            if (! empty($excludeKeywords)) {
95
-                $excludeCondition = ! (bool) preg_match('/'.implode('|', $excludeKeywords).'/', $name);
94
+            if (!empty($excludeKeywords)) {
95
+                $excludeCondition = !(bool) preg_match('/' . implode('|', $excludeKeywords) . '/', $name);
96 96
             }
97 97
 
98 98
             return $includeCondition && $excludeCondition;
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
         foreach ($keywords as $keyword) {
121 121
             if (Str::startsWith($keyword, ['-', '\\-'])) {
122 122
                 $excludeKeywords[] = str_replace(['-', '\\'], '', $keyword);
123
-            }  else {
123
+            } else {
124 124
                 $includeKeywords[] = $keyword;
125 125
             }
126 126
         }
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@
 block discarded – undo
120 120
         foreach ($keywords as $keyword) {
121 121
             if (Str::startsWith($keyword, ['-', '\\-'])) {
122 122
                 $excludeKeywords[] = str_replace(['-', '\\'], '', $keyword);
123
-            }  else {
123
+            } else {
124 124
                 $includeKeywords[] = $keyword;
125 125
             }
126 126
         }
Please login to merge, or discard this patch.