Implement both blocklists and in-player blocking

This commit is contained in:
TC
2023-05-08 22:23:11 +02:00
parent c488c30015
commit 69f560cdd1
5 changed files with 338 additions and 10 deletions

View File

@ -0,0 +1,13 @@
const { PluginConfig } = require("../../config/dynamic");
const config = new PluginConfig("adblocker", { enableFront: true });
const blockers = {
WithBlocklists: "With blocklists",
InPlayer: "In player",
};
const shouldUseBlocklists = async () =>
(await config.get("blocker")) !== blockers.InPlayer;
module.exports = { shouldUseBlocklists, blockers, ...config };