Fix crashes & settings on canary

This commit is contained in:
Vendicated 2024-06-17 23:00:25 +02:00
parent c1593e1806
commit 098124175f
No known key found for this signature in database
GPG key ID: D66986BAF75ECF18
2 changed files with 12 additions and 1 deletions

View file

@ -182,7 +182,7 @@ export default definePlugin({
patchedSettings: new WeakSet(),
addSettings(elements: any[], element: { header?: string; settings: string[]; }, sectionTypes: SectionTypes) {
if (this.patchedSettings.has(elements) || !this.isRightSpot(element)) return;
if (this.patchedSettings.has(elements)) return;
this.patchedSettings.add(elements);

View file

@ -42,7 +42,18 @@ const subscribedFluxEventsPlugins = new Set<string>();
const pluginsValues = Object.values(Plugins);
const settings = Settings.plugins;
const forceDisabled = new Set([
"MessageLogger",
"ShowHiddenChannels",
"MoreUserTags",
"Decor",
"IgnoreActivities",
"NoBlockedMessages",
"BetterFolders",
"NoPendingCount"
]);
export function isPluginEnabled(p: string) {
if (forceDisabled.has(p)) return false;
return (
Plugins[p]?.required ||
Plugins[p]?.isDependency ||