Completed
Pull Request — master (#272)
by
unknown
04:44
created
src/Repository.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
     {
100 100
         $paths = $this->paths;
101 101
 
102
-        $paths[] = $this->getPath() . '/*';
102
+        $paths[] = $this->getPath().'/*';
103 103
 
104 104
         if ($this->config('scan.enabled')) {
105 105
             $paths = array_merge($paths, $this->config('scan.paths'));
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
         $modules = [];
161 161
 
162 162
         foreach ($cached as $name => $module) {
163
-            $path = $this->config('paths.modules') . '/' . $name;
163
+            $path = $this->config('paths.modules').'/'.$name;
164 164
 
165 165
             $modules[$name] = new Module($this->app, $name, $path);
166 166
         }
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
      */
176 176
     public function getCached()
177 177
     {
178
-        return $this->app['cache']->remember($this->config('cache.key'), $this->config('cache.lifetime'), function () {
178
+        return $this->app['cache']->remember($this->config('cache.key'), $this->config('cache.lifetime'), function() {
179 179
             return $this->toCollection()->toArray();
180 180
         });
181 181
     }
@@ -263,7 +263,7 @@  discard block
 block discarded – undo
263 263
     {
264 264
         $modules = $this->enabled();
265 265
 
266
-        uasort($modules, function (Module $a, Module $b) use ($direction) {
266
+        uasort($modules, function(Module $a, Module $b) use ($direction) {
267 267
             if ($a->order == $b->order) {
268 268
                 return 0;
269 269
             }
@@ -412,9 +412,9 @@  discard block
 block discarded – undo
412 412
     public function getModulePath($module)
413 413
     {
414 414
         try {
415
-            return $this->findOrFail($module)->getPath() . '/';
415
+            return $this->findOrFail($module)->getPath().'/';
416 416
         } catch (ModuleNotFoundException $e) {
417
-            return $this->getPath() . '/' . Str::studly($module) . '/';
417
+            return $this->getPath().'/'.Str::studly($module).'/';
418 418
         }
419 419
     }
420 420
 
@@ -427,7 +427,7 @@  discard block
 block discarded – undo
427 427
      */
428 428
     public function assetPath($module)
429 429
     {
430
-        return $this->config('paths.assets') . '/' . $module;
430
+        return $this->config('paths.assets').'/'.$module;
431 431
     }
432 432
 
433 433
     /**
@@ -440,7 +440,7 @@  discard block
 block discarded – undo
440 440
      */
441 441
     public function config($key, $default = null)
442 442
     {
443
-        return $this->app['config']->get('modules.' . $key, $default);
443
+        return $this->app['config']->get('modules.'.$key, $default);
444 444
     }
445 445
 
446 446
     /**
@@ -525,9 +525,9 @@  discard block
 block discarded – undo
525 525
         }
526 526
         list($name, $url) = explode(':', $asset);
527 527
 
528
-        $baseUrl = str_replace(public_path() . DIRECTORY_SEPARATOR, '', $this->getAssetsPath());
528
+        $baseUrl = str_replace(public_path().DIRECTORY_SEPARATOR, '', $this->getAssetsPath());
529 529
 
530
-        $url = $this->app['url']->asset($baseUrl . "/{$name}/" . $url);
530
+        $url = $this->app['url']->asset($baseUrl."/{$name}/".$url);
531 531
 
532 532
         return str_replace(['http://', 'https://'], '//', $url);
533 533
     }
Please login to merge, or discard this patch.
src/LaravelModulesServiceProvider.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
      */
57 57
     public function setupStubPath()
58 58
     {
59
-        Stub::setBasePath(__DIR__ . '/Commands/stubs');
59
+        Stub::setBasePath(__DIR__.'/Commands/stubs');
60 60
 
61 61
         switch (get_class($this->app)) {
62 62
             // // Lumen doesn't support boot()
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
                 }
67 67
                 break;
68 68
             default:
69
-                $this->app->booted(function ($app) {
69
+                $this->app->booted(function($app) {
70 70
                     if ($app['modules']->config('stubs.enabled') === true) {
71 71
                         Stub::setBasePath($app['modules']->config('stubs.path'));
72 72
                     }
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
      */
81 81
     protected function registerNamespaces()
82 82
     {
83
-        $configPath = __DIR__ . '/../config/config.php';
83
+        $configPath = __DIR__.'/../config/config.php';
84 84
 
85 85
         $this->mergeConfigFrom($configPath, 'modules');
86 86
         $this->publishes([
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
      */
94 94
     protected function registerServices()
95 95
     {
96
-        $this->app->singleton('modules', function ($app) {
96
+        $this->app->singleton('modules', function($app) {
97 97
             $path = $app['config']->get('modules.paths.modules');
98 98
 
99 99
             return new Repository($app, $path);
Please login to merge, or discard this patch.