diff --git a/app/Helpers/HelperFunctions.php b/app/Helpers/HelperFunctions.php index 856733e..00d8dc0 100644 --- a/app/Helpers/HelperFunctions.php +++ b/app/Helpers/HelperFunctions.php @@ -90,7 +90,7 @@ function getChampionImage($full_id, $type): string function getCommitHash(): string { /** @var string $commit */ - $commit = Cache::remember('commit_hash', 60 * 72, fn() => trim(exec('git log --pretty="%h" -n1 HEAD'))); + $commit = Cache::remember('commit_hash', 60 * 72, fn () => trim(exec('git log --pretty="%h" -n1 HEAD'))); return $commit; } diff --git a/app/Http/Controllers/ContactSubmissionController.php b/app/Http/Controllers/ContactSubmissionController.php index ada2cbf..f280b16 100644 --- a/app/Http/Controllers/ContactSubmissionController.php +++ b/app/Http/Controllers/ContactSubmissionController.php @@ -23,7 +23,7 @@ class ContactSubmissionController extends Controller $descriptionContent .= ' -**Discord**: ' . $contactSubmission->discord; +**Discord**: '.$contactSubmission->discord; } DiscordAlert::message(sprintf('There is a new contact submission from %s (%s).', $contactSubmission->name, $contactSubmission->email), [ diff --git a/app/Http/Controllers/PostsController.php b/app/Http/Controllers/PostsController.php index 3efd004..76e3328 100644 --- a/app/Http/Controllers/PostsController.php +++ b/app/Http/Controllers/PostsController.php @@ -10,7 +10,7 @@ class PostsController extends Controller { public function index() { - $posts = Sheets::all()->filter(fn($post) => ! $post->hidden)->sortByDesc('date'); + $posts = Sheets::all()->filter(fn ($post) => ! $post->hidden)->sortByDesc('date'); $paginatedPosts = Paginate::collection($posts, 6); return view('posts.index', [ diff --git a/app/Models/Streamer.php b/app/Models/Streamer.php index 40be5b7..76752b3 100644 --- a/app/Models/Streamer.php +++ b/app/Models/Streamer.php @@ -28,11 +28,11 @@ class Streamer extends Model public function getStreamerUrlAttribute(): string { return match ($this->platform) { - 'Twitch' => 'https://www.twitch.tv/' . $this->username, - 'YouTube' => 'https://www.youtube.com/@' . $this->username, - 'Kick' => 'https://kick.com/' . $this->username, - 'Douyu' => 'https://www.douyu.com/' . $this->username, - 'Huya' => 'https://www.huya.com/' . $this->username, + 'Twitch' => 'https://www.twitch.tv/'.$this->username, + 'YouTube' => 'https://www.youtube.com/@'.$this->username, + 'Kick' => 'https://kick.com/'.$this->username, + 'Douyu' => 'https://www.douyu.com/'.$this->username, + 'Huya' => 'https://www.huya.com/'.$this->username, }; } diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php index 599aa00..efb3f53 100644 --- a/app/Providers/AppServiceProvider.php +++ b/app/Providers/AppServiceProvider.php @@ -46,14 +46,14 @@ class AppServiceProvider extends ServiceProvider public function bootAuth(): void { - Gate::define('viewPulse', fn(User $user) => $user->admin); + Gate::define('viewPulse', fn (User $user) => $user->admin); } public function bootRoute(): void { - RateLimiter::for('api', fn(Request $request) => Limit::perMinute(60)->by($request->user()?->id ?: $request->ip())); + RateLimiter::for('api', fn (Request $request) => Limit::perMinute(60)->by($request->user()?->id ?: $request->ip())); - Route::bind('post', fn($path) => $this->app->make(Sheets::class) + Route::bind('post', fn ($path) => $this->app->make(Sheets::class) ->collection('posts') ->get($path) ?? abort(404)); }