@@ -15,7 +15,7 @@ |
||
15 | 15 | |
16 | 16 | $url = Url::whereRaw('lower(path) = (?)', [$path])->where(['active' => 1])->first(); |
17 | 17 | |
18 | - if (! $url) { |
|
18 | + if (!$url) { |
|
19 | 19 | return redirect('/'); |
20 | 20 | } |
21 | 21 |
@@ -11,7 +11,7 @@ |
||
11 | 11 | { |
12 | 12 | $url = URL::select(['long_url', 'path', 'created_at'])->where(['path' => $path, 'active' => 1])->first(); |
13 | 13 | |
14 | - if (! $url) { |
|
14 | + if (!$url) { |
|
15 | 15 | return redirect('/'); |
16 | 16 | } |
17 | 17 |
@@ -29,10 +29,10 @@ discard block |
||
29 | 29 | } |
30 | 30 | |
31 | 31 | if ($search) { |
32 | - $query->where(function (Builder $query) use ($search) { |
|
32 | + $query->where(function(Builder $query) use ($search) { |
|
33 | 33 | $query->where('path', 'LIKE', "%{$search}%") |
34 | 34 | ->orWhere('long_url', 'LIKE', "%{$search}%") |
35 | - ->orWhereHas('user', function ($query) use ($search) { |
|
35 | + ->orWhereHas('user', function($query) use ($search) { |
|
36 | 36 | $query->where('name', 'LIKE', "%{$search}%") |
37 | 37 | ->orWhere('email', 'LIKE', "%{$search}%"); |
38 | 38 | }); |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | Validator::make([ |
114 | 114 | 'path' => $path |
115 | 115 | ], [ |
116 | - 'path' => ['required', 'alpha_dash', 'min:' . config('tinre.min_path_length'), 'max:' . config('tinre.max_path_length')], |
|
116 | + 'path' => ['required', 'alpha_dash', 'min:'.config('tinre.min_path_length'), 'max:'.config('tinre.max_path_length')], |
|
117 | 117 | ])->validate(); |
118 | 118 | |
119 | 119 | $path = strtolower($path); |