init
This commit is contained in:
commit
5c8ac17e02
2 changed files with 61 additions and 0 deletions
13
LICENSE
Normal file
13
LICENSE
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||||
|
Version 2, December 2004
|
||||||
|
|
||||||
|
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
|
||||||
|
|
||||||
|
Everyone is permitted to copy and distribute verbatim or modified
|
||||||
|
copies of this license document, and changing it is allowed as long
|
||||||
|
as the name is changed.
|
||||||
|
|
||||||
|
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||||
|
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||||
|
|
||||||
|
0. You just DO WHAT THE FUCK YOU WANT TO.
|
48
index.ts
Normal file
48
index.ts
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
/*
|
||||||
|
* Vencord, a Discord client mod
|
||||||
|
* Copyright (c) 2025 Vendicated and contributors
|
||||||
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { definePluginSettings } from "@api/Settings";
|
||||||
|
import { Devs } from "@utils/constants";
|
||||||
|
import definePlugin, { OptionType } from "@utils/types";
|
||||||
|
|
||||||
|
const settings = definePluginSettings({
|
||||||
|
disableSpotify: {
|
||||||
|
default: true,
|
||||||
|
type: OptionType.BOOLEAN,
|
||||||
|
description: "Do not send track history to Discord"
|
||||||
|
},
|
||||||
|
disableGames: {
|
||||||
|
default: true,
|
||||||
|
type: OptionType.BOOLEAN,
|
||||||
|
description: "Do not send game activity to Discord"
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
export default definePlugin({
|
||||||
|
name: "NoActivityFeedSend",
|
||||||
|
description: "Disables sending activity/Spotify history to Discord, effectively hiding it from activity history",
|
||||||
|
authors: [Devs.nin0dev],
|
||||||
|
enabledByDefault: true,
|
||||||
|
settings,
|
||||||
|
patches: [
|
||||||
|
{
|
||||||
|
find: "for_game_profile",
|
||||||
|
replacement: {
|
||||||
|
match: /await \i.\i.post\({url:\i.\i.MY_SPOTIFY_CONTENT_INVENTORY.{0,100}}\)/,
|
||||||
|
replace: "(()=>{})()"
|
||||||
|
},
|
||||||
|
predicate: () => settings.store.disableSpotify
|
||||||
|
},
|
||||||
|
{
|
||||||
|
find: "MY_CONTENT_INVENTORY_APPLICATION(",
|
||||||
|
replacement: {
|
||||||
|
match: /await \i.\i.post\({url:\i.\i.MY_CONTENT_INVENTORY_APPLICATION.{0,100}}\)/,
|
||||||
|
replace: "(()=>{})()"
|
||||||
|
},
|
||||||
|
predicate: () => settings.store.disableGames
|
||||||
|
}
|
||||||
|
]
|
||||||
|
});
|
Loading…
Add table
Reference in a new issue