From 85275d447347617d745586dde1882967aa7d39b6 Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Sun, 22 Jan 2023 21:39:12 +0100 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Hypolite Petovan --- twitter/twitter.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/twitter/twitter.php b/twitter/twitter.php index f35ff8d3..5aeecf30 100644 --- a/twitter/twitter.php +++ b/twitter/twitter.php @@ -1288,7 +1288,7 @@ function twitter_fetchtimeline(int $uid): void $osecret = DI::pConfig()->get($uid, 'twitter', 'oauthsecret'); $lastid = DI::pConfig()->get($uid, 'twitter', 'lastid'); - $application_name = DI::keyValue()->get('twitter_application_name'); + $application_name = DI::keyValue()->get('twitter_application_name') ?? ''; if ($application_name == '') { $application_name = DI::baseUrl()->getHostname(); @@ -2187,7 +2187,7 @@ function twitter_fetchhometimeline(int $uid): void Logger::info('Fetching timeline', ['uid' => $uid]); - $application_name = DI::keyValue()->get('twitter_application_name'); + $application_name = DI::keyValue()->get('twitter_application_name') ?? ''; if ($application_name == '') { $application_name = DI::baseUrl()->getHostname(); -- 2.39.5