@@ -18,38 +18,38 @@ discard block |
||
18 | 18 | $key = $instance->makeCacheKey(); |
19 | 19 | |
20 | 20 | return $instance->cache($tags) |
21 | - ->rememberForever($key, function () use ($columns) { |
|
21 | + ->rememberForever($key, function() use ($columns) { |
|
22 | 22 | return parent::all($columns); |
23 | 23 | }); |
24 | 24 | } |
25 | 25 | |
26 | 26 | public static function bootCachable() |
27 | 27 | { |
28 | - static::created(function ($instance) { |
|
28 | + static::created(function($instance) { |
|
29 | 29 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
30 | 30 | }); |
31 | 31 | |
32 | - static::deleted(function ($instance) { |
|
32 | + static::deleted(function($instance) { |
|
33 | 33 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
34 | 34 | }); |
35 | 35 | |
36 | - static::saved(function ($instance) { |
|
36 | + static::saved(function($instance) { |
|
37 | 37 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
38 | 38 | }); |
39 | 39 | |
40 | - static::restored(function ($instance) { |
|
40 | + static::restored(function($instance) { |
|
41 | 41 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
42 | 42 | }); |
43 | 43 | |
44 | - static::pivotAttached(function ($instance) { |
|
44 | + static::pivotAttached(function($instance) { |
|
45 | 45 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
46 | 46 | }); |
47 | 47 | |
48 | - static::pivotDetached(function ($instance) { |
|
48 | + static::pivotDetached(function($instance) { |
|
49 | 49 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
50 | 50 | }); |
51 | 51 | |
52 | - static::pivotUpdated(function ($instance) { |
|
52 | + static::pivotUpdated(function($instance) { |
|
53 | 53 | $instance->checkCooldownAndFlushAfterPersiting($instance); |
54 | 54 | }); |
55 | 55 | } |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | |
66 | 66 | public function newEloquentBuilder($query) |
67 | 67 | { |
68 | - if (! $this->isCachable()) { |
|
68 | + if (!$this->isCachable()) { |
|
69 | 69 | $this->isCachable = true; |
70 | 70 | |
71 | 71 | return new EloquentBuilder($query); |
@@ -92,13 +92,13 @@ discard block |
||
92 | 92 | $cacheKey = "{$cachePrefix}:{$modelClassName}-cooldown:seconds"; |
93 | 93 | |
94 | 94 | $this->cache() |
95 | - ->rememberForever($cacheKey, function () use ($seconds) { |
|
95 | + ->rememberForever($cacheKey, function() use ($seconds) { |
|
96 | 96 | return $seconds; |
97 | 97 | }); |
98 | 98 | |
99 | 99 | $cacheKey = "{$cachePrefix}:{$modelClassName}-cooldown:invalidated-at"; |
100 | 100 | $this->cache() |
101 | - ->rememberForever($cacheKey, function () { |
|
101 | + ->rememberForever($cacheKey, function() { |
|
102 | 102 | return (new Carbon)->now(); |
103 | 103 | }); |
104 | 104 |