From c66762abe743cc43ce414aaaf2a672bd62633346 Mon Sep 17 00:00:00 2001 From: Yorhel Date: Sun, 8 Dec 2019 08:06:24 +0100 Subject: Discussions: Add exception for uid 2 in sql_visible_threads() Turns out the recent update didn't allow me to moderate private threads anymore. :( I decided not make it a boardmod feature this time, one person for moderating private threads is enough. --- lib/VNWeb/Discussions/Lib.pm | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/VNWeb') diff --git a/lib/VNWeb/Discussions/Lib.pm b/lib/VNWeb/Discussions/Lib.pm index 4ab1900c..f2d6c98d 100644 --- a/lib/VNWeb/Discussions/Lib.pm +++ b/lib/VNWeb/Discussions/Lib.pm @@ -15,6 +15,7 @@ sub post_url { # Returns a WHERE condition to filter threads that the current user is allowed to see. sub sql_visible_threads { + return '1=1' if auth && auth->uid == 2; # Yorhel sees everything sql_and auth->permBoardmod ? () : ('NOT t.hidden'), sql('NOT t.private OR EXISTS(SELECT 1 FROM threads_boards WHERE tid = t.id AND type = \'u\' AND iid =', \auth->uid, ')'); -- cgit v1.2.3