diff --git a/api/funkwhale_api/plugins/dynamic_preferences_registry.py b/api/funkwhale_api/plugins/dynamic_preferences_registry.py new file mode 100644 index 000000000..5b7929b69 --- /dev/null +++ b/api/funkwhale_api/plugins/dynamic_preferences_registry.py @@ -0,0 +1,14 @@ +from dynamic_preferences import types +from dynamic_preferences.registries import global_preferences_registry + +plugins = types.Section("plugins") + + +@global_preferences_registry.register +class PluginsEnabled(types.BooleanPreference): + section = plugins + show_in_api = True + name = "enabled" + default = True + verbose_name = "Enable Funkwhale plugins" + help_text = "If disabled, all installed and enabled plugins will be ignored."