Passed
Push — master ( c780f6...60df12 )
by Andres
02:52
created
src/JSLocalizationServiceProvider.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -20,11 +20,11 @@  discard block
 block discarded – undo
20 20
 
21 21
         Blade::directive('jslocalization', function($expression) {
22 22
             $auxExpression = explode(',', str_replace(['(', ')', ' ', '"', "'"], '', $expression));
23
-            if (count($auxExpression) > 2) {
23
+            if (count($auxExpression)>2) {
24 24
                 $langfile = $auxExpression[0];
25 25
                 $group = $auxExpression[1];
26 26
                 $basevar = $auxExpression[2];
27
-            } elseif (count($auxExpression) > 1) {
27
+            } elseif (count($auxExpression)>1) {
28 28
                 $langfile = $auxExpression[0];
29 29
                 $group = $auxExpression[1];
30 30
                 $basevar = "";
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
         Blade::directive('jsmodel', function($expression) {
40 40
             $auxExpression = explode(',', str_replace(['(', ')', ' ', '"', "'"], '', $expression));
41 41
             //echo "<pre>" . print_r($auxExpression, true) . "</pre>";
42
-            if (count($auxExpression) > 1) {
42
+            if (count($auxExpression)>1) {
43 43
                 if ($auxExpression[0] == 'Auth::user') {
44 44
                     $model = \Auth::user();
45 45
                 } else {
Please login to merge, or discard this patch.
src/BindTranslationsToJS.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -107,7 +107,7 @@
 block discarded – undo
107 107
             }
108 108
             $jsarray = json_encode($model);
109 109
             return "<script>{$variable} = {$jsarray};</script>";
110
-        }else{
110
+        } else {
111 111
             
112 112
         }
113 113
     }
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -101,13 +101,13 @@
 block discarded – undo
101 101
             }
102 102
             $jsarray = $model->toJson();
103 103
             return "<script>{$variable} = {$jsarray};</script>";
104
-        }elseif (is_array($model)) {
104
+        } elseif (is_array($model)) {
105 105
             if ($variable == "") {
106 106
                 $variable = "varArray";
107 107
             }
108 108
             $jsarray = json_encode($model);
109 109
             return "<script>{$variable} = {$jsarray};</script>";
110
-        }else{
110
+        } else{
111 111
             
112 112
         }
113 113
     }
Please login to merge, or discard this patch.