Added sub-objects for api toggles (WIP)
This commit is contained in:
parent
5eec98d127
commit
31ffd0d185
2 changed files with 45 additions and 31 deletions
|
|
@ -20,7 +20,7 @@ export abstract class APIModel {
|
|||
abstract getById(id: string): Promise<MediaTypeModel>;
|
||||
|
||||
hasType(type: MediaType): boolean {
|
||||
if (this.types.contains(type) && !(this.plugin.settings[(this.apiName + type) as keyof MediaDbPluginSettings] === false)) {
|
||||
if (this.types.contains(type) && !(this.plugin.settings[((`${this.apiName}"."${type}`)) as keyof MediaDbPluginSettings] === false)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue