From 6bc8103ca2b341b4a7d15996a64502ac00d5c626 Mon Sep 17 00:00:00 2001 From: Michael Date: Sat, 27 Oct 2018 12:40:59 +0000 Subject: [PATCH] Avoid a notice in twitter.php --- twitter/twitter.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/twitter/twitter.php b/twitter/twitter.php index d3440d53..f60625e6 100644 --- a/twitter/twitter.php +++ b/twitter/twitter.php @@ -1801,6 +1801,9 @@ function twitter_fetch_own_contact(App $a, $uid) // Fetching user data // get() may throw TwitterOAuthException, but we will catch it later $user = $connection->get('account/verify_credentials'); + if (empty($user) || empty($user->id_str)) { + return false; + } PConfig::set($uid, 'twitter', 'own_id', $user->id_str); -- 2.39.5