Passed
Pull Request — master (#47)
by Lloric Mayuga
03:49 queued 43s
created
src/LaravelTimezoneServiceProvider.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -26,8 +26,8 @@  discard block
 block discarded – undo
26 26
     public function boot()
27 27
     {
28 28
         // for lumen
29
-        $configPath = function ($path = '') {
30
-            return app()->basePath().'/config'.($path ? '/'.$path : $path);
29
+        $configPath = function($path = '') {
30
+            return app()->basePath() . '/config' . ($path ? '/' . $path : $path);
31 31
         };
32 32
 
33 33
         // Register an event listener
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         // Allow config publish
37 37
         $this->publishes(
38 38
             [
39
-                __DIR__.'/config/timezone.php' => $configPath('timezone.php'),
39
+                __DIR__ . '/config/timezone.php' => $configPath('timezone.php'),
40 40
             ],
41 41
             'config'
42 42
         );
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
         // Register a blade directive to show user date/time in their timezone
45 45
         Blade::directive(
46 46
             'displayDate',
47
-            function ($expression) {
47
+            function($expression) {
48 48
                 $options = explode(',', $expression);
49 49
 
50 50
                 if (count($options) == 1) {
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
     public function register()
69 69
     {
70 70
         $this->mergeConfigFrom(
71
-            __DIR__.'/config/timezone.php',
71
+            __DIR__ . '/config/timezone.php',
72 72
             'timezone'
73 73
         );
74 74
     }
Please login to merge, or discard this patch.
src/Timezone.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
         $formatted_date_time = $date->format($format);
31 31
 
32 32
         if ($format_timezone) {
33
-            return $formatted_date_time.' '.self::formatTimezone($date);
33
+            return $formatted_date_time . ' ' . self::formatTimezone($date);
34 34
         }
35 35
 
36 36
         return $formatted_date_time;
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
         $parts = explode('/', $timezone);
58 58
 
59 59
         if (count($parts) > 1) {
60
-            return str_replace('_', ' ', $parts[1]).', '.$parts[0];
60
+            return str_replace('_', ' ', $parts[1]) . ', ' . $parts[0];
61 61
         }
62 62
 
63 63
         return str_replace('_', ' ', $parts[0]);
Please login to merge, or discard this patch.
src/Listeners/Auth/UpdateUsersTimezone.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
             return;
54 54
         }
55 55
 
56
-        $message = 'We have set your timezone to '.$geoip_info['timezone'];
56
+        $message = 'We have set your timezone to ' . $geoip_info['timezone'];
57 57
 
58 58
         if (config('timezone.flash') == 'laravel') {
59 59
             request()->session()->flash('success', $message);
Please login to merge, or discard this patch.