Passed
Branch master (b6c3d8)
by F
03:53
created
src/Traits/HasAddresses.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
         $addresses = collect($addresses)
65 65
             ->flatten()
66 66
             ->map(
67
-                function ($address) {
67
+                function($address) {
68 68
                     if (true === empty($address)) {
69 69
                         return false;
70 70
                     }
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
                 }
74 74
             )
75 75
             ->filter(
76
-                function ($address) {
76
+                function($address) {
77 77
                     return $address instanceof Address;
78 78
                 }
79 79
             )
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
             $class = \get_class($model);
90 90
 
91 91
             $class::saved(
92
-                function ($object) use ($addresses, $model) {
92
+                function($object) use ($addresses, $model) {
93 93
                     static $modelLastFiredOn;
94 94
                     if (null !== $modelLastFiredOn && $modelLastFiredOn === $model) {
95 95
                         return;
Please login to merge, or discard this patch.
src/Controllers/LanguageController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@
 block discarded – undo
15 15
      *
16 16
      * @return \Illuminate\Http\RedirectResponse
17 17
      */
18
-    public function switch($locale)
18
+    public function switch ($locale)
19 19
     {
20 20
         $locales = (array) Language::getLocales();
21 21
 
Please login to merge, or discard this patch.
src/LocalisationRegistrar.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -224,9 +224,9 @@  discard block
 block discarded – undo
224 224
     {
225 225
         if (null === $this->addresses) {
226 226
             $this->addresses = $this->cache->remember(
227
-                self::$cacheKey . '.addresses',
227
+                self::$cacheKey.'.addresses',
228 228
                 self::$cacheExpirationTime,
229
-                function () {
229
+                function() {
230 230
                     return $this->getAddressModel()
231 231
                         //->with('system_address_types')
232 232
                         ->get();
@@ -257,7 +257,7 @@  discard block
 block discarded – undo
257 257
             $this->languages = $this->cache->remember(
258 258
                 self::$cacheKey,
259 259
                 self::$cacheExpirationTime,
260
-                function () {
260
+                function() {
261 261
                     return $this->getLanguageClass()
262 262
                     //->with('countries')
263 263
                         ->get();
Please login to merge, or discard this patch.
src/Localisation.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@
 block discarded – undo
84 84
         } else if ($locale === $fallbackLocale) {
85 85
             $locale = 'en-GB';
86 86
         } else {
87
-            $locale = $fallbackLocale . '-' . strtoupper($fallbackLocale);
87
+            $locale = $fallbackLocale.'-'.strtoupper($fallbackLocale);
88 88
         }
89 89
 
90 90
         try {
Please login to merge, or discard this patch.
src/LocalisationServiceProvider.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
     public function register()
31 31
     {
32 32
         $this->mergeConfigFrom(
33
-            __DIR__ . '/../config/localisation.php',
33
+            __DIR__.'/../config/localisation.php',
34 34
             'pwweb.localisation'
35 35
         );
36 36
 
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
         $this->app->make('PWWEB\Localisation\Controllers\IndexController');
39 39
 
40 40
         // Register views.
41
-        $this->loadViewsFrom(__DIR__ . '/resources/views', 'localisation');
41
+        $this->loadViewsFrom(__DIR__.'/resources/views', 'localisation');
42 42
     }
43 43
 
44 44
     /**
@@ -51,34 +51,34 @@  discard block
 block discarded – undo
51 51
      */
52 52
     public function boot(LocalisationRegistrar $localisationLoader, Filesystem $filesystem)
53 53
     {
54
-        include __DIR__ . '/../routes/web.php';
54
+        include __DIR__.'/../routes/web.php';
55 55
 
56 56
         if (true === function_exists('config_path')) {
57 57
             // function not available and 'publish' not relevant in Lumen
58 58
             $this->publishes(
59 59
                 [
60
-                    __DIR__ . '/../config/localisation.php' => config_path('pwweb/localisation.php'),
60
+                    __DIR__.'/../config/localisation.php' => config_path('pwweb/localisation.php'),
61 61
                 ],
62 62
                 'pwweb.localisation.config'
63 63
             );
64 64
 
65 65
             $this->publishes(
66 66
                 [
67
-                    __DIR__ . '/../database/migrations/create_localisation_tables.php.stub' => $this->getMigrationFileName($filesystem),
67
+                    __DIR__.'/../database/migrations/create_localisation_tables.php.stub' => $this->getMigrationFileName($filesystem),
68 68
                 ],
69 69
                 'pwweb.localisation.migrations'
70 70
             );
71 71
 
72 72
             $this->publishes(
73 73
                 [
74
-                    __DIR__ . '/resources/lang' => resource_path('lang/vendor/pwweb'),
74
+                    __DIR__.'/resources/lang' => resource_path('lang/vendor/pwweb'),
75 75
                 ],
76 76
                 'pwweb.localisation.language'
77 77
             );
78 78
 
79 79
             $this->publishes(
80 80
                 [
81
-                    __DIR__ . '/resources/views' => base_path('resources/views/vendor/localisation'),
81
+                    __DIR__.'/resources/views' => base_path('resources/views/vendor/localisation'),
82 82
                 ],
83 83
                 'pwweb.localisation.views'
84 84
             );
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
             ]
91 91
         );
92 92
 
93
-        $this->loadTranslationsFrom(realpath(__DIR__ . '/resources/lang'), 'pwweb');
93
+        $this->loadTranslationsFrom(realpath(__DIR__.'/resources/lang'), 'pwweb');
94 94
         // dd(app()->getLocale());
95 95
         // echo '<pre>';
96 96
         // print_r($this->app['translator']);
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
 
107 107
         $this->app->singleton(
108 108
             LocalisationRegistrar::class,
109
-            function ($app) use ($localisationLoader) {
109
+            function($app) use ($localisationLoader) {
110 110
                 return $localisationLoader;
111 111
             }
112 112
         );
@@ -140,12 +140,12 @@  discard block
 block discarded – undo
140 140
     {
141 141
         $timestamp = date('Y_m_d_His', mktime(0, 0, 0, 1, 1, 2020));
142 142
 
143
-        return Collection::make($this->app->databasePath() . DIRECTORY_SEPARATOR . 'migrations' . DIRECTORY_SEPARATOR)
143
+        return Collection::make($this->app->databasePath().DIRECTORY_SEPARATOR.'migrations'.DIRECTORY_SEPARATOR)
144 144
             ->flatMap(
145
-                function ($path) use ($filesystem) {
146
-                    return $filesystem->glob($path . '*_create_localisation_tables.php');
145
+                function($path) use ($filesystem) {
146
+                    return $filesystem->glob($path.'*_create_localisation_tables.php');
147 147
                 }
148
-            )->push($this->app->databasePath() . "/migrations/{$timestamp}_create_localisation_tables.php")
148
+            )->push($this->app->databasePath()."/migrations/{$timestamp}_create_localisation_tables.php")
149 149
             ->first();
150 150
     }
151 151
 }
Please login to merge, or discard this patch.
src/Models/Country.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,6 +60,6 @@
 block discarded – undo
60 60
             return '';
61 61
         }
62 62
 
63
-        return __('pwweb::localization.' . $value);
63
+        return __('pwweb::localization.'.$value);
64 64
     }
65 65
 }
Please login to merge, or discard this patch.
src/Models/Address/Type.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,6 +103,6 @@
 block discarded – undo
103 103
             return '';
104 104
         }
105 105
 
106
-        return __('pwweb::localisation.' . $value);
106
+        return __('pwweb::localisation.'.$value);
107 107
     }
108 108
 }
Please login to merge, or discard this patch.