Completed
Push — master ( a7d6e5...e7c634 )
by Iman
02:13
created
src/WidgetGenerator.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
 
7 7
 class WidgetGenerator extends LaravelGeneratorCommand 
8 8
 {
9
-	/**
9
+    /**
10 10
      * The name and signature of the console command.
11 11
      *
12 12
      * @var string
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
     protected function getStub()
36 36
     {
37 37
        
38
-		return __DIR__.'/../stubs/widget.stub';
38
+        return __DIR__.'/../stubs/widget.stub';
39 39
        
40 40
     }
41 41
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
     protected function getStub()
36 36
     {
37 37
        
38
-		return __DIR__.'/../stubs/widget.stub';
38
+		return __DIR__ . '/../stubs/widget.stub';
39 39
        
40 40
     }
41 41
 
Please login to merge, or discard this patch.
src/WidgetsServiceProvider.php 2 patches
Indentation   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -7,32 +7,32 @@
 block discarded – undo
7 7
 
8 8
 class WidgetsServiceProvider extends ServiceProvider {
9 9
 
10
-	/**
11
-	 * Bootstrap any application services.
12
-	 *
13
-	 * @return void
14
-	 */
15
-	public function boot()
16
-	{
10
+    /**
11
+     * Bootstrap any application services.
12
+     *
13
+     * @return void
14
+     */
15
+    public function boot()
16
+    {
17 17
         $this->loadViewsFrom($this->app->basePath().'/app/Widgets/', 'Widgets');
18
-	}
18
+    }
19 19
 
20
-	/**
21
-	 * Register any application services.
22
-	 *
23
-	 * This service provider is a great spot to register your various container
24
-	 * bindings with the application. As you can see, we are registering our
25
-	 * "Registrar" implementation here. You can add your own bindings too!
26
-	 *
27
-	 * @return void
28
-	 */
29
-	public function register()
30
-	{
31
-		$this->app->singleton('command.imanghafoori.widget', function ($app) {
20
+    /**
21
+     * Register any application services.
22
+     *
23
+     * This service provider is a great spot to register your various container
24
+     * bindings with the application. As you can see, we are registering our
25
+     * "Registrar" implementation here. You can add your own bindings too!
26
+     *
27
+     * @return void
28
+     */
29
+    public function register()
30
+    {
31
+        $this->app->singleton('command.imanghafoori.widget', function ($app) {
32 32
             return $app['Imanghafoori\Widgets\WidgetGenerator'];
33 33
         });
34 34
 		
35 35
         $this->commands('command.imanghafoori.widget');
36
-	}
36
+    }
37 37
 
38 38
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
 	 */
15 15
 	public function boot()
16 16
 	{
17
-        $this->loadViewsFrom($this->app->basePath().'/app/Widgets/', 'Widgets');
17
+        $this->loadViewsFrom($this->app->basePath() . '/app/Widgets/', 'Widgets');
18 18
 	}
19 19
 
20 20
 	/**
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 	 */
29 29
 	public function register()
30 30
 	{
31
-		$this->app->singleton('command.imanghafoori.widget', function ($app) {
31
+		$this->app->singleton('command.imanghafoori.widget', function($app) {
32 32
             return $app['Imanghafoori\Widgets\WidgetGenerator'];
33 33
         });
34 34
 		
Please login to merge, or discard this patch.
src/BaseWidget.php 2 patches
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -300,6 +300,10 @@
 block discarded – undo
300 300
         return md5(json_encode($arg, JSON_FORCE_OBJECT) . $this->template . get_called_class());
301 301
     }
302 302
 
303
+    /**
304
+     * @param string $key
305
+     * @param \Closure $phpCode
306
+     */
303 307
     private function cacheResult($key, $phpCode)
304 308
     {
305 309
         $cache = app()->make('cache');
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -175,7 +175,7 @@
 block discarded – undo
175 175
     private function generateHtml(...$args)
176 176
     {
177 177
         // Everything inside this function is executed only when the cache is not available.
178
-        $expensivePhpCode = function () use ($args) {
178
+        $expensivePhpCode = function() use ($args) {
179 179
             $this->prepareDataForView($args);
180 180
 
181 181
             // render the template with the resulting data.
Please login to merge, or discard this patch.