cw lists can contain words and domains

merge-requests/30/head
Bob Mottram 2021-10-21 12:17:26 +01:00
parent b8c957eb38
commit d16942976b
2 changed files with 9 additions and 5 deletions

View File

@ -890,9 +890,12 @@ def loadLists(baseDir: str, verbose: bool) -> {}:
listJson = loadJson(listFilename)
if not listJson:
continue
if listJson.get('name') and listJson.get('domains'):
name = listJson['name']
if verbose:
print('List: ' + name)
result[name] = listJson
if not listJson.get('name'):
continue
if not listJson('words') and not listJson.get('domains'):
continue
name = listJson['name']
if verbose:
print('List: ' + name)
result[name] = listJson
return result

View File

@ -1,6 +1,7 @@
{
"name": "Murdoch press",
"warning": "Murdoch Press",
"words": [],
"domains": [
api.news,
content.api.news,