Removed autoUpvote config

This commit is contained in:
Ajay Ramachandran 2020-05-20 23:50:26 -04:00
parent 0f82c16940
commit f165b3b602
3 changed files with 5 additions and 25 deletions

View file

@ -380,12 +380,6 @@
"currentInstances": {
"message": "Current Instances:"
},
"enableAutoUpvote": {
"message": "Auto Upvote"
},
"whatAutoUpvote": {
"message": "With this enabled, the extension will upvote all submissions you view if you do not report them. If the notice is disabled, this will not occur."
},
"minDuration": {
"message": "Minimum duration (seconds):"
},

View file

@ -237,23 +237,6 @@
<br/>
<br/>
<div option-type="toggle" sync-option="autoUpvote">
<label class="switch-container" label-name="__MSG_enableAutoUpvote__">
<label class="switch">
<input type="checkbox" checked>
<span class="slider round"></span>
</label>
</label>
<br/>
<br/>
<div class="small-description">__MSG_whatAutoUpvote__</div>
</div>
<br/>
<br/>
<div option-type="toggle" sync-option="trackViewCount">
<label class="switch-container" label-name="__MSG_enableViewTracking__">
<label class="switch">

View file

@ -24,7 +24,6 @@ interface SBConfig {
hideDiscordLaunches: number,
hideDiscordLink: boolean,
invidiousInstances: string[],
autoUpvote: boolean,
supportInvidious: boolean,
serverAddress: string,
minDuration: number,
@ -124,7 +123,6 @@ var Config: SBObject = {
hideDiscordLaunches: 0,
hideDiscordLink: false,
invidiousInstances: ["invidio.us", "invidious.snopyta.org"],
autoUpvote: true,
supportInvidious: false,
serverAddress: CompileConfig.serverAddress,
minDuration: 0,
@ -252,6 +250,11 @@ async function migrateOldFormats() {
}
}
// Auto vote removal
if (Config.config["autoUpvote"]) {
chrome.storage.sync.remove("autoUpvote");
}
// Channel URLS
if (Config.config.whitelistedChannels.length > 0 &&
(Config.config.whitelistedChannels[0] == null || Config.config.whitelistedChannels[0].includes("/"))) {