| @@ -14,7 +14,7 @@ | ||
| 14 | 14 |                  ->where('slug', $slug) | 
| 15 | 15 | ->first(); | 
| 16 | 16 | |
| 17 | -        if (! $page) { | |
| 17 | +        if (!$page) { | |
| 18 | 18 | return abort(404); | 
| 19 | 19 | } | 
| 20 | 20 | |
| @@ -20,7 +20,7 @@ | ||
| 20 | 20 |              __DIR__.'/../config/simple-pages.php' => base_path('config/simple-pages.php'), | 
| 21 | 21 | ], 'config'); | 
| 22 | 22 | |
| 23 | -        if (! class_exists('CreateSimplePagesTable')) { | |
| 23 | +        if (!class_exists('CreateSimplePagesTable')) { | |
| 24 | 24 | $this->publishes([ | 
| 25 | 25 |                  __DIR__.'/../database/migrations/create_simple_pages_table.php.stub' => database_path('migrations/'.date('Y_m_d_His', time()).'_create_simple_pages_table.php'), | 
| 26 | 26 | ], 'migrations'); | 
| @@ -36,7 +36,7 @@ discard block | ||
| 36 | 36 | 'deleted_at', | 
| 37 | 37 | ]; | 
| 38 | 38 | |
| 39 | - public function __construct(array $attributes = []) | |
| 39 | + public function __construct(array $attributes = [ ]) | |
| 40 | 40 |      { | 
| 41 | 41 | parent::__construct($attributes); | 
| 42 | 42 | |
| @@ -76,13 +76,13 @@ discard block | ||
| 76 | 76 | public function scopePublished($query) | 
| 77 | 77 |      { | 
| 78 | 78 |          return $query->where('public', true) | 
| 79 | -            ->where(function ($query) { | |
| 79 | +            ->where(function($query) { | |
| 80 | 80 | $today = (new Carbon)->toDateString(); | 
| 81 | 81 | |
| 82 | -                $query->where(function ($query) use ($today) { | |
| 82 | +                $query->where(function($query) use ($today) { | |
| 83 | 83 |                      $query->whereDate('public_from', '<=', $today)->orWhereNull('public_from'); | 
| 84 | 84 | }) | 
| 85 | -                ->where(function ($query) use ($today) { | |
| 85 | +                ->where(function($query) use ($today) { | |
| 86 | 86 |                      $query->whereDate('public_until', '>=', $today)->orWhereNull('public_until'); | 
| 87 | 87 | }); | 
| 88 | 88 | }); |