From a835996db7a761861cb425ebda85fd34379abb68 Mon Sep 17 00:00:00 2001 From: enes Date: Thu, 16 Jan 2025 13:06:16 +0100 Subject: [PATCH] refactor(mutelist): no need to check admin specific list for isBlocked --- src/pages/blog/loader.ts | 7 ------- src/pages/mod/loader.ts | 8 +------- 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/src/pages/blog/loader.ts b/src/pages/blog/loader.ts index 08df1de..b5657e1 100644 --- a/src/pages/blog/loader.ts +++ b/src/pages/blog/loader.ts @@ -161,13 +161,6 @@ export const blogRouteLoader = } if ( - isAdmin && - muteLists.value.admin.replaceableEvents.includes(result.blog.aTag) - ) { - result.isBlocked = true - } - if ( - !isAdmin && muteLists.value.user.replaceableEvents.includes(result.blog.aTag) ) { result.isBlocked = true diff --git a/src/pages/mod/loader.ts b/src/pages/mod/loader.ts index 38e6c55..afc7fa9 100644 --- a/src/pages/mod/loader.ts +++ b/src/pages/mod/loader.ts @@ -166,14 +166,8 @@ export const modRouteLoader = result.postWarning = 'admin' } + // Check if user has blocked this profile if ( - isAdmin && - muteLists.value.admin.replaceableEvents.includes(result.mod.aTag) - ) { - result.isBlocked = true - } - if ( - !isAdmin && muteLists.value.user.replaceableEvents.includes(result.mod.aTag) ) { result.isBlocked = true