diff options
Diffstat (limited to 'src/plugins/showHiddenChannels/components')
-rw-r--r-- | src/plugins/showHiddenChannels/components/HiddenChannelLockScreen.tsx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/showHiddenChannels/components/HiddenChannelLockScreen.tsx b/src/plugins/showHiddenChannels/components/HiddenChannelLockScreen.tsx index 506fbe7..d01efec 100644 --- a/src/plugins/showHiddenChannels/components/HiddenChannelLockScreen.tsx +++ b/src/plugins/showHiddenChannels/components/HiddenChannelLockScreen.tsx @@ -26,6 +26,7 @@ import type { Channel } from "discord-types/general"; import type { ComponentType } from "react"; import openRolesAndUsersPermissionsModal, { PermissionType, RoleOrUserPermission } from "../../permissionsViewer/components/RolesAndUsersPermissions"; +import { sortPermissionOverwrites } from "../../permissionsViewer/utils"; import { settings, VIEW_CHANNEL } from ".."; enum SortOrderTypes { @@ -169,12 +170,12 @@ function HiddenChannelLockScreen({ channel }: { channel: ExtendedChannel; }) { } if (Settings.plugins.PermissionsViewer.enabled) { - setPermissions(Object.values(permissionOverwrites).map(overwrite => ({ + setPermissions(sortPermissionOverwrites(Object.values(permissionOverwrites).map(overwrite => ({ type: overwrite.type as PermissionType, id: overwrite.id, overwriteAllow: overwrite.allow, overwriteDeny: overwrite.deny - }))); + })), guild_id)); } }, [channelId]); |