File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,16 @@ async function main() {
3737 'extra'
3838 ] ;
3939
40+ const filters = [
41+ 'category' ,
42+ 'project' ,
43+ 'license' ,
44+ 'organization' ,
45+ 'headquarters' ,
46+ 'company type' ,
47+ 'industry'
48+ ] ;
49+
4050 const addKeyError = ( title , key ) => {
4151 hasInvalidKeys = true ;
4252 errors . push ( `${ title } has an unknown key: ${ key } ` ) ;
@@ -180,6 +190,12 @@ async function main() {
180190 }
181191 }
182192
193+ const disabledFilters = settings . big_picture . main . disabled_filters || [ ] ;
194+ const nonExistentFilter = disabledFilters . find ( filter => ! ( filters . includes ( filter . toLowerCase ( ) ) ) ) ;
195+ if ( nonExistentFilter ) {
196+ errors . push ( `"${ nonExistentFilter } " is included in disabled_filters but is not a recognised filter` ) ;
197+ }
198+
183199 errors . forEach ( function ( error ) {
184200 setFatalError ( error ) ;
185201 } ) ;
You can’t perform that action at this time.
0 commit comments