From: rabuzarus <> Date: Thu, 1 Jun 2017 10:47:47 +0000 (+0200) Subject: restructure the conditions if gnetwork and gaddr is empty X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=8806688d686ad44f0072b73846baafa5f9de1d02;p=friendica.git restructure the conditions if gnetwork and gaddr is empty --- diff --git a/include/NotificationsManager.php b/include/NotificationsManager.php index 96af0b76c2..ad0ede6dbe 100644 --- a/include/NotificationsManager.php +++ b/include/NotificationsManager.php @@ -850,13 +850,13 @@ class NotificationsManager { // get the missing data data from other sources if ($arr['gnetwork'] == "" || $arr['gaddr'] == "") { $ret = get_contact_details_by_url($arr['url']); - } - if ($arr['gnetwork'] == "") { - $arr['gnetwork'] = $ret['network']; - } - if ($arr['gaddr'] == "") { - $arr['gaddr'] = $ret['addr']; + if ($arr['gnetwork'] == "" && $ret['network'] != "") { + $arr['gnetwork'] = $ret['network']; + } + if ($arr['gaddr'] == "" && $ret['addr'] != "") { + $arr['gaddr'] = $ret['addr']; + } } return $arr;