mirror of
https://github.com/Equicord/Equicord.git
synced 2025-02-24 00:59:09 -05:00
Fix Lint
This commit is contained in:
parent
f57580a4ba
commit
2b57bd86cd
1 changed files with 13 additions and 13 deletions
|
@ -127,7 +127,7 @@ const settings = definePluginSettings({
|
|||
type: OptionType.BOOLEAN,
|
||||
default: true,
|
||||
onChange: (value: boolean) => {
|
||||
if (!value) preMid.clearActivity();
|
||||
if (!value) clearActivity();
|
||||
},
|
||||
},
|
||||
showButtons: {
|
||||
|
@ -147,9 +147,17 @@ const settings = definePluginSettings({
|
|||
}
|
||||
});
|
||||
|
||||
function clearActivity() {
|
||||
FluxDispatcher.dispatch({
|
||||
type: "LOCAL_ACTIVITY_UPDATE",
|
||||
activity: null,
|
||||
socketId: "PreMiD",
|
||||
});
|
||||
}
|
||||
|
||||
const Native = VencordNative.pluginHelpers.PreMiD as PluginNative<typeof import("./native")>;
|
||||
|
||||
const preMid = definePlugin({
|
||||
export default definePlugin({
|
||||
name: "PreMiD",
|
||||
tags: ["presence", "premid", "rpc", "watching"],
|
||||
description: "A PreMiD app replacement. Supports watching/listening status. Requires extra setup (see settings)",
|
||||
|
@ -158,7 +166,7 @@ const preMid = definePlugin({
|
|||
"Toggle presence sharing": () => {
|
||||
settings.store.enableSet = !settings.store.enableSet;
|
||||
showToast(`Presence sharing is now ${settings.store.enableSet ? "enabled" : "disabled"}`);
|
||||
preMid.clearActivity();
|
||||
clearActivity();
|
||||
},
|
||||
},
|
||||
|
||||
|
@ -177,6 +185,8 @@ const preMid = definePlugin({
|
|||
</>
|
||||
),
|
||||
|
||||
clearActivity,
|
||||
|
||||
settings,
|
||||
logger,
|
||||
|
||||
|
@ -189,14 +199,6 @@ const preMid = definePlugin({
|
|||
Native.disconnect();
|
||||
},
|
||||
|
||||
clearActivity() {
|
||||
FluxDispatcher.dispatch({
|
||||
type: "LOCAL_ACTIVITY_UPDATE",
|
||||
activity: null,
|
||||
socketId: "PreMiD",
|
||||
});
|
||||
},
|
||||
|
||||
showToast,
|
||||
|
||||
async receiveActivity(data: PresenceData) {
|
||||
|
@ -323,5 +325,3 @@ function showToast(msg: string) {
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
export default preMid;
|
||||
|
|
Loading…
Add table
Reference in a new issue