From 46aaf2d7b7a8759a216415adfc1b4a54322bef58 Mon Sep 17 00:00:00 2001 From: xiaomlove Date: Wed, 12 Oct 2022 01:42:43 +0800 Subject: [PATCH] fix user that has permission can not see uploader on torrent table --- include/constants.php | 2 +- include/functions.php | 2 +- public/details.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/constants.php b/include/constants.php index ae443d6e..4f96d1f0 100644 --- a/include/constants.php +++ b/include/constants.php @@ -1,6 +1,6 @@ ".$lang_functions['text_anonymous']."
".(isset($row["owner"]) ? "(" . get_username($row["owner"]) .")" : "".$lang_functions['text_orphaned']."") . "\n"); } diff --git a/public/details.php b/public/details.php index 33bbeb9f..b6a440bd 100644 --- a/public/details.php +++ b/public/details.php @@ -101,7 +101,7 @@ if (!$row) { // ------------- start upped by block ------------------// if($row['anonymous'] == 'yes') { - if (!user_can('viewanonymous')) + if (!user_can('viewanonymous') && $row['owner'] != $CURUSER['id']) $uprow = "".$lang_details['text_anonymous'].""; else $uprow = "".$lang_details['text_anonymous']." (" . get_username($row['owner'], false, true, true, false, false, true) . ")";