From 45748da8a1d0580e5f1cd81c34ec3b807ed8ea3b Mon Sep 17 00:00:00 2001
From: Hypolite Petovan <hypolite@mrpetovan.com>
Date: Wed, 17 Oct 2018 01:11:50 -0400
Subject: [PATCH] Remove network exception in handle_tag

---
 mod/item.php | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/mod/item.php b/mod/item.php
index 053a00c977..4d798ac1e5 100644
--- a/mod/item.php
+++ b/mod/item.php
@@ -1015,11 +1015,7 @@ function handle_tag(App $a, &$body, &$inform, &$str_tags, $profile_uid, $tag, $n
 
 			$profile = $contact["url"];
 			$alias   = $contact["alias"];
-			$newname = $contact["nick"];
-
-			if (($newname == "") || !in_array($contact["network"], [Protocol::ACTIVITYPUB, Protocol::OSTATUS, Protocol::TWITTER, Protocol::STATUSNET])) {
-				$newname = $contact["name"];
-			}
+			$newname = defaults($contact, "name", $contact["nick"]);
 		}
 
 		//if there is an url for this persons profile