ShowHiddenChannels: Fix showing lock icon for special channels (#3460)

This commit is contained in:
Henry 2025-06-04 19:24:04 -05:00 committed by GitHub
parent db0bcf7da3
commit 503c90c201
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 0 deletions

View file

@ -498,6 +498,7 @@ export default definePlugin({
if (channel.channelId != null) channel = ChannelStore.getChannel(channel.channelId);
if (channel == null || channel.isDM() || channel.isGroupDM() || channel.isMultiUserDM()) return false;
if (["browse", "customize", "guide"].includes(channel.id)) return false;
return !PermissionStore.can(PermissionsBits.VIEW_CHANNEL, channel) || checkConnect && !PermissionStore.can(PermissionsBits.CONNECT, channel);
} catch (e) {