aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/fakeNitro.ts
diff options
context:
space:
mode:
authorNuckyz <61953774+Nuckyz@users.noreply.github.com>2023-09-12 05:01:18 -0300
committerNuckyz <61953774+Nuckyz@users.noreply.github.com>2023-09-12 05:01:18 -0300
commit4222c7fd9f0bc7b23f121b78d1f33a811a10f7ad (patch)
tree4578d58ee9e6fc84a8390d3216e0ee199260823a /src/plugins/fakeNitro.ts
parent09f65b401e53827035ed83d9363ddbd4a1d875c6 (diff)
downloadVencord-4222c7fd9f0bc7b23f121b78d1f33a811a10f7ad.tar.gz
Vencord-4222c7fd9f0bc7b23f121b78d1f33a811a10f7ad.tar.bz2
Vencord-4222c7fd9f0bc7b23f121b78d1f33a811a10f7ad.zip
Fix broken FakeNitro patch on canary
Diffstat (limited to 'src/plugins/fakeNitro.ts')
-rw-r--r--src/plugins/fakeNitro.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/fakeNitro.ts b/src/plugins/fakeNitro.ts
index d74a6c0..669da19 100644
--- a/src/plugins/fakeNitro.ts
+++ b/src/plugins/fakeNitro.ts
@@ -212,15 +212,15 @@ export default definePlugin({
}
},
{
- find: "canStreamHighQuality:function",
+ find: "canUseHighVideoUploadQuality:function",
predicate: () => settings.store.enableStreamQualityBypass,
replacement: [
"canUseHighVideoUploadQuality",
- "canStreamHighQuality",
- "canStreamMidQuality"
+ // TODO: Remove the last two when they get removed from stable
+ "(?:canStreamQuality|canStreamHighQuality|canStreamMidQuality)",
].map(func => {
return {
- match: new RegExp(`${func}:function\\(\\i\\){`),
+ match: new RegExp(`${func}:function\\(\\i(?:,\\i)?\\){`),
replace: "$&return true;"
};
})