CustomUserColors: Fix Patch

This commit is contained in:
thororen1234 2025-07-28 17:42:43 -04:00
parent eb70fdf85c
commit 26bf65e5d9
No known key found for this signature in database
3 changed files with 4 additions and 9 deletions

View file

@ -7,9 +7,7 @@
// https://github.com/Masterjoona/vc-betterplusreacts/blob/main/index.ts
import { Devs } from "@utils/constants";
import definePlugin from "@utils/types";
import { findByPropsLazy } from "@webpack";
const { getMessages } = findByPropsLazy("getMessages");
import { MessageStore } from "@webpack/common";
export default definePlugin({
name: "BetterPlusReacts",
@ -56,6 +54,7 @@ export default definePlugin({
return message;
},
setMsgReference(plusses: string, channelId: string) {
const { getMessages } = MessageStore;
this.message = getMessages(channelId).getByIndex(getMessages(channelId).length - plusses.split("+").length + 1);
}
});

View file

@ -127,7 +127,7 @@ export default definePlugin({
{
find: '"Reply Chain Nudge")',
replacement: {
match: /(,color:)(\i),/,
match: /(,colorString:)(\i),/,
replace: "$1$self.colorInReplyingTo(arguments[0]) ?? $2,",
},
},

View file

@ -17,7 +17,7 @@
*/
import * as t from "@vencord/discord-types";
import { findByCodeLazy, findByPropsLazy, waitFor } from "@webpack";
import { findByCodeLazy, findByPropsLazy } from "@webpack";
import { waitForStore } from "./internal";
@ -86,7 +86,3 @@ waitForStore("ThemeStore", m => {
Vencord.QuickCss.initQuickCssThemeStore();
});
waitForStore("VoiceStateStore", m => VoiceStateStore = m);
// GuildRoleStore is new, this code is for stable + canary compatibility
// TODO: Change to waitForStore once GuildRoleStore is on stable
waitFor(["getRole", "getRoles"], m => GuildRoleStore = m);