X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Ftagrm.php;h=179276663b0fc5e60dba427ccae776c39d4d5d55;hb=aa0b485f3dca72c5448076e913fa54d948cd7731;hp=7e8ae8524b92a78a8be0a4cddfcc3549e62766a6;hpb=7de6e60328a6b5878f988f3421d5beabd0264d4a;p=friendica.git diff --git a/mod/tagrm.php b/mod/tagrm.php index 7e8ae8524b..179276663b 100644 --- a/mod/tagrm.php +++ b/mod/tagrm.php @@ -44,7 +44,6 @@ function tagrm_post(App $a) $item_id = $_POST['item'] ?? 0; update_tags($item_id, $tags); - info(DI::l10n()->t('Tag(s) removed') . EOL); DI::baseUrl()->redirect($_SESSION['photo_return']); // NOTREACHED @@ -97,15 +96,16 @@ function tagrm_content(App $a) // NOTREACHED } - $item = Item::selectFirst(['tag'], ['id' => $item_id, 'uid' => local_user()]); + $item = Item::selectFirst(['uri-id'], ['id' => $item_id, 'uid' => local_user()]); if (!DBA::isResult($item)) { DI::baseUrl()->redirect($_SESSION['photo_return']); } - $arr = explode(',', $item['tag']); + $tag_text = Tag::getCSVByURIId($item['uri-id']); + $arr = explode(',', $tag_text); - if (empty($item['tag'])) { + if (empty($arr)) { DI::baseUrl()->redirect($_SESSION['photo_return']); }