Skip to content
This repository was archived by the owner on Apr 23, 2026. It is now read-only.

Commit a0d6a70

Browse files
authored
Merge pull request #159 from Vendicated/main
[pull] mybuild from Vendicated:main
2 parents 49973c8 + 50c5124 commit a0d6a70

22 files changed

Lines changed: 52 additions & 91 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "vencord",
33
"private": "true",
4-
"version": "1.14.1",
4+
"version": "1.14.2",
55
"description": "The cutest Discord client mod",
66
"homepage": "https://github.com/Vendicated/Vencord#readme",
77
"bugs": {

packages/discord-types/src/components.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ export type Select = ComponentType<PropsWithChildren<{
243243
export type SearchableSelect = ComponentType<PropsWithChildren<{
244244
placeholder?: string;
245245
options: ReadonlyArray<SelectOption>; // TODO
246-
value?: SelectOption;
246+
value?: any;
247247

248248
/**
249249
* - 0 ~ Filled

src/plugins/_api/commands.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@ export default definePlugin({
5555
{
5656
// ...children: p?.name
5757
match: /(?<=:(\i)\.displayDescription\}.{0,200}children:).{0,50}\.name(?=\}\))/,
58-
replace: "$1.plugin||($&)"
58+
replace: "$1.plugin||($&)",
59+
noWarn: true // TODO: remove legacy compatibility code in the future
5960
},
6061
{
6162
match: /children:(?=\i\?\?\i\?\.name)(?<=command:(\i),.+?)/,

src/plugins/betterFolders/index.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ import "./style.css";
2121
import { definePluginSettings } from "@api/Settings";
2222
import { Devs } from "@utils/constants";
2323
import { getIntlMessage } from "@utils/discord";
24+
import { Logger } from "@utils/Logger";
2425
import definePlugin, { OptionType } from "@utils/types";
2526
import { findByPropsLazy, findStoreLazy } from "@webpack";
2627
import { FluxDispatcher } from "@webpack/common";
@@ -341,7 +342,13 @@ export default definePlugin({
341342
}
342343

343344
try {
344-
return child?.props?.["aria-label"] === getIntlMessage("SERVERS");
345+
// can cause hang if intl message is not found
346+
const serversIntlMsg = getIntlMessage("SERVERS");
347+
if (!serversIntlMsg) {
348+
new Logger("BetterFolders").error("Failed to get SERVERS intl message");
349+
return true;
350+
}
351+
return child?.props?.["aria-label"] === serversIntlMsg;
345352
} catch (e) {
346353
console.error(e);
347354
return true;

src/plugins/betterGifPicker/index.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@ export default definePlugin({
1515
{
1616
find: "renderHeaderContent(){",
1717
replacement: [
18-
{
19-
match: /(?<="state",{resultType:)null/,
20-
replace: '"Favorites"'
21-
},
2218
{
2319
match: /(?<=state={resultType:)null/,
2420
replace: '"Favorites"'

src/plugins/betterSettings/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ export default definePlugin({
139139
find: "#{intl::USER_SETTINGS_ACTIONS_MENU_LABEL}",
140140
replacement: [
141141
{
142-
match: /=\[\];(\i)(?=\.forEach.{0,100}"logout"!==\i.{0,30}(\i)\.get\(\i\))/,
142+
match: /=\[\];(\i)(?=\.forEach.{0,200}?"logout"===\i.{0,100}?(\i)\.get\(\i\))/,
143143
replace: "=$self.wrapMap([]);$self.transformSettingsEntries($1,$2)",
144144
predicate: () => settings.store.organizeMenu
145145
},

src/plugins/consoleJanitor/index.tsx

Lines changed: 4 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -148,10 +148,6 @@ export default definePlugin({
148148
{
149149
find: "is not a valid locale.",
150150
replacement: [
151-
{
152-
match: /\i\.error(?=\(""\.concat\(\i," is not a valid locale."\)\))/,
153-
replace: "$self.Noop"
154-
},
155151
{
156152
match: /\i\.error(?=\(`\$\{\i\} is not a valid locale.`)/,
157153
replace: "$self.Noop"
@@ -167,16 +163,10 @@ export default definePlugin({
167163
},
168164
{
169165
find: "RPCServer:WSS",
170-
replacement: [
171-
{
172-
match: /\i\.error\("Error: "\.concat\((\i)\.message/,
173-
replace: '!$1.message.includes("EADDRINUSE")&&$&'
174-
},
175-
{
176-
match: /\i\.error\(`Error: \$\{(\i)\.message\}/,
177-
replace: '!$1.message.includes("EADDRINUSE")&&$&'
178-
}
179-
]
166+
replacement: {
167+
match: /\i\.error\(`Error: \$\{(\i)\.message\}/,
168+
replace: '!$1.message.includes("EADDRINUSE")&&$&'
169+
}
180170
},
181171
{
182172
find: "Tried getting Dispatch instance before instantiated",
@@ -195,10 +185,6 @@ export default definePlugin({
195185
{
196186
find: "failed to send analytics events",
197187
replacement: [
198-
{
199-
match: /console\.error\("\[analytics\] failed to send analytics events query: "\.concat\(\i\)\)/,
200-
replace: ""
201-
},
202188
{
203189
match: /console\.error\(`\[analytics\] failed to send analytics events query: \$\{\i\}`\)/,
204190
replace: ""

src/plugins/disableCallIdle/index.ts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,20 @@ export default definePlugin({
2525
authors: [Devs.Nuckyz],
2626
patches: [
2727
{
28-
find: "#{intl::BOT_CALL_IDLE_DISCONNECT_2}",
28+
find: "this.idleTimeout.start(",
2929
replacement: {
30-
match: /,?(?=\i\(this,"idleTimeout",new \i\.\i\))/,
31-
replace: ";return;"
30+
match: /this\.idleTimeout\.(start|stop)/g,
31+
replace: "$self.noop"
3232
}
3333
},
3434
{
3535
find: "handleIdleUpdate(){",
3636
replacement: {
37-
match: /(?<=_initialize\(\){)/,
38-
replace: "return;"
37+
match: "handleIdleUpdate(){",
38+
replace: "handleIdleUpdate(){return;"
3939
}
4040
}
41-
]
41+
],
42+
43+
noop() { }
4244
});

src/plugins/mentionAvatars/index.tsx

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -49,16 +49,10 @@ export default definePlugin({
4949

5050
patches: [{
5151
find: ".USER_MENTION)",
52-
replacement: [
53-
{
54-
match: /children:"@"\.concat\((null!=\i\?\i:\i)\)(?<=\.useName\((\i)\).+?)/,
55-
replace: "children:$self.renderUsername({username:$1,user:$2})"
56-
},
57-
{
58-
match: /children:`@\$\{(\i\?\?\i)\}`(?<=\.useName\((\i)\).+?)/,
59-
replace: "children:$self.renderUsername({username:$1,user:$2})"
60-
}
61-
]
52+
replacement: {
53+
match: /children:`@\$\{(\i\?\?\i)\}`(?<=\.useName\((\i)\).+?)/,
54+
replace: "children:$self.renderUsername({username:$1,user:$2})"
55+
}
6256
},
6357
{
6458
find: ".ROLE_MENTION)",

src/plugins/pinDms/components/CreateCategoryModal.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ interface ColorPickerWithSwatchesProps {
2424

2525
const ColorPickerWithSwatches = findComponentByCodeLazy<ColorPickerWithSwatchesProps>('id:"color-picker"');
2626

27-
export const requireSettingsMenu = extractAndLoadChunksLazy(['name:"UserSettings"'], /createPromise:.{0,20}(\i\.\i\("?.+?"?\).*?).then\(\i\.bind\(\i,"?(.+?)"?\)\).{0,50}"UserSettings"/);
27+
export const requireSettingsModal = extractAndLoadChunksLazy(['type:"USER_SETTINGS_MODAL_OPEN"']);
2828

2929
const cl = classNameFactory("vc-pindms-modal-");
3030

@@ -119,7 +119,7 @@ export function NewCategoryModal({ categoryId, modalProps, initialChannelId }: P
119119

120120
export const openCategoryModal = (categoryId: string | null, channelId: string | null) =>
121121
openModalLazy(async () => {
122-
await requireSettingsMenu();
122+
await requireSettingsModal();
123123
return modalProps => <NewCategoryModal categoryId={categoryId} modalProps={modalProps} initialChannelId={channelId} />;
124124
});
125125

0 commit comments

Comments
 (0)