Completed
Push — master ( b4e56c...1b6c56 )
by Avtandil
04:39
created
src/MultiLang/Console/MigrationCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
                 $this->info('Migration successfully created!');
54 54
             } else {
55 55
                 $this->error(
56
-                    'Couldn\'t create migration.'.PHP_EOL.' Check the write permissions
56
+                    'Couldn\'t create migration.' . PHP_EOL . ' Check the write permissions
57 57
                     within the database/migrations directory.'
58 58
                 );
59 59
             }
Please login to merge, or discard this patch.
src/MultiLang/TextsTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,10 +24,10 @@
 block discarded – undo
24 24
             $options['scope'] = $request->scope;
25 25
         }
26 26
 
27
-        $texts = Text::where(function ($q) use ($options) {
27
+        $texts = Text::where(function($q) use ($options) {
28 28
             foreach ($options as $k => $v) {
29 29
                 if ($k == 'keyword') {
30
-                    $q->where(function ($query) use ($v) {
30
+                    $q->where(function($query) use ($v) {
31 31
                         $query->where('key', 'LIKE', '%' . $v . '%')->orWhere('value', 'LIKE', '%' . $v . '%');
32 32
                     });
33 33
                 } else {
Please login to merge, or discard this patch.
src/MultiLang/MultiLang.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -288,9 +288,9 @@
 block discarded – undo
288 288
 
289 289
         foreach ($locales as $locale => $val) {
290 290
             $router->group([
291
-                               'prefix' => $locale,
292
-                               'as'     => $locale . '.',
293
-                           ], $callback);
291
+                                'prefix' => $locale,
292
+                                'as'     => $locale . '.',
293
+                            ], $callback);
294 294
         }
295 295
 
296 296
     }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -263,7 +263,7 @@
 block discarded – undo
263 263
      */
264 264
     protected function sortReplacements(array $replace)
265 265
     {
266
-        return (new Collection($replace))->sortBy(function ($value, $key) {
266
+        return (new Collection($replace))->sortBy(function($value, $key) {
267 267
             return mb_strlen($key) * -1;
268 268
         });
269 269
     }
Please login to merge, or discard this patch.
src/MultiLang/Repository.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -203,11 +203,11 @@
 block discarded – undo
203 203
                 $this->getDb()
204 204
                     ->table($table)
205 205
                     ->insert([
206
-                                 'key'   => $k,
207
-                                 'lang'  => $lang,
208
-                                 'scope' => $scope,
209
-                                 'value' => $v,
210
-                             ]);
206
+                                    'key'   => $k,
207
+                                    'lang'  => $lang,
208
+                                    'scope' => $scope,
209
+                                    'value' => $v,
210
+                                ]);
211 211
             }
212 212
         }
213 213
         return true;
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@
 block discarded – undo
82 82
             ->where('lang', $lang);
83 83
 
84 84
         if (!is_null($scope)) {
85
-            $query = $query->whereNested(function ($query) use ($scope) {
85
+            $query = $query->whereNested(function($query) use ($scope) {
86 86
                 $query->where('scope', 'global');
87 87
                 $query->orWhere('scope', $scope);
88 88
             });
Please login to merge, or discard this patch.
src/MultiLang/MultiLangServiceProvider.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,9 +35,9 @@
 block discarded – undo
35 35
     {
36 36
         // Publish config files
37 37
         $this->publishes([
38
-                             __DIR__ . '/../config/config.php' => config_path('multilang.php'),
39
-                             __DIR__ . '/../views'             => base_path('resources/views/vendor/multilang'),
40
-                         ]);
38
+                                __DIR__ . '/../config/config.php' => config_path('multilang.php'),
39
+                                __DIR__ . '/../views'             => base_path('resources/views/vendor/multilang'),
40
+                            ]);
41 41
 
42 42
         // Append the country settings
43 43
         $this->mergeConfigFrom(
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -46,11 +46,11 @@  discard block
 block discarded – undo
46 46
         );
47 47
 
48 48
         // Register blade directives
49
-        Blade::directive('t', function ($expression) {
49
+        Blade::directive('t', function($expression) {
50 50
             return "<?php echo e(t({$expression})); ?>";
51 51
         });
52 52
 
53
-        $this->app['events']->listen(RouteMatched::class, function () {
53
+        $this->app['events']->listen(RouteMatched::class, function() {
54 54
             $scope = $this->app['config']->get('app.scope');
55 55
             if ($scope && $scope != 'global') {
56 56
                 $this->app['multilang']->setScope($scope);
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
         $configPath = __DIR__ . '/../config/config.php';
72 72
         $this->mergeConfigFrom($configPath, 'debugbar');
73 73
 
74
-        $this->app->singleton('multilang', function ($app) {
74
+        $this->app->singleton('multilang', function($app) {
75 75
             $environment = $app->environment();
76 76
             $config      = $app['config']->get('multilang');
77 77
 
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
             );
84 84
 
85 85
             if ($multilang->autoSaveIsAllowed()) {
86
-                $app->terminating(function () use ($multilang) {
86
+                $app->terminating(function() use ($multilang) {
87 87
                     $scope = $this->app['config']->get('app.scope');
88 88
                     if ($scope && $scope != 'global') {
89 89
                         $multilang->setScope($scope);
@@ -98,13 +98,13 @@  discard block
 block discarded – undo
98 98
         $this->app->alias('multilang', 'Longman\LaravelMultiLang\MultiLang');
99 99
 
100 100
         $this->app['command.multilang.migration'] = $this->app->share(
101
-            function () {
101
+            function() {
102 102
                 return new MigrationCommand();
103 103
             }
104 104
         );
105 105
 
106 106
         $this->app['command.multilang.texts'] = $this->app->share(
107
-            function () {
107
+            function() {
108 108
                 return new TextsCommand();
109 109
             }
110 110
         );
Please login to merge, or discard this patch.