This commit is contained in:
thororen1234 2024-06-03 14:31:45 -04:00
parent 8b7229b100
commit 66b7a92c15

View file

@ -47,7 +47,7 @@ export default definePlugin({
patches: [
{
find: ".Messages.MUTUAL_GUILDS_WITH_END_COUNT",
find: ".Messages.MUTUAL_GUILDS_WITH_END_COUNT", // Note: the module is lazy-loaded
replacement: {
match: /(?<=\.tabBarItem.{0,50}MUTUAL_GUILDS.+?}\),)(?=.+?(\(0,\i\.jsxs?\)\(.{0,100}id:))/,
replace: '(arguments[0].user.bot||arguments[0].isCurrentUser)?null:$1"MUTUAL_GDMS",children:"Mutual Groups"}),'
@ -85,7 +85,6 @@ export default definePlugin({
const label = "Mutual Group";
return state > 0 ? pluralise(state, label) : `No ${label}s`;
},
renderMutualGDMs: ErrorBoundary.wrap(({ user, onClose }: { user: User, onClose: () => void; }) => {
const entries = ChannelStore.getSortedPrivateChannels().filter(c => c.isGroupDM() && c.recipients.includes(user.id)).map(c => (
<Clickable