From 77585aa96233bdcead5a03afaea2723fe07bf068 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20=C5=A0tancl?= Date: Sun, 10 Oct 2021 18:32:00 +0200 Subject: [PATCH] PHP 7.4 support --- app/Models/Tip.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Models/Tip.php b/app/Models/Tip.php index 10cde5b..d890796 100644 --- a/app/Models/Tip.php +++ b/app/Models/Tip.php @@ -74,7 +74,7 @@ class Tip extends Model 'title' => (string) Str::of(Str::of($tweet->text)->explode("\n")->first())->rtrim('.')->replaceMatches('/^([^a-zA-Z]*)/', ''), // remove any non-ascii characters from the beginning 'content' => (string) Str::of($tweet->text)->explode("\n")->skip(1)->join("\n"), 'tweet_id' => $tweet->id, - 'thread_slug' => $threadSlug ?? Thread::firstWhere('tweet_id', $tweet->threadId)?->slug, + 'thread_slug' => $threadSlug ?? optional(Thread::firstWhere('tweet_id', $tweet->threadId))->slug, 'author_username' => Author::firstOrCreate([ 'username' => $tweet->author->username, 'name' => $tweet->author->name,