Scope seen, missing, and unique per media type
Also drop unused "dupes" list
This commit is contained in:
parent
4a67ece43d
commit
973adc0148
@ -161,14 +161,13 @@ def org_diff(lst_dicts, media_type, main_server):
|
|||||||
}
|
}
|
||||||
"""
|
"""
|
||||||
diff_dict = {}
|
diff_dict = {}
|
||||||
seen = {}
|
|
||||||
dupes = []
|
|
||||||
missing = []
|
|
||||||
unique = []
|
|
||||||
# todo-me pull posters from connected servers
|
# todo-me pull posters from connected servers
|
||||||
|
|
||||||
for mtype in media_type:
|
for mtype in media_type:
|
||||||
meta_lst = []
|
meta_lst = []
|
||||||
|
seen = {}
|
||||||
|
missing = []
|
||||||
|
unique = []
|
||||||
print('...combining {}s'.format(mtype))
|
print('...combining {}s'.format(mtype))
|
||||||
for server_lst in lst_dicts:
|
for server_lst in lst_dicts:
|
||||||
for item in server_lst[mtype]:
|
for item in server_lst[mtype]:
|
||||||
@ -184,7 +183,6 @@ def org_diff(lst_dicts, media_type, main_server):
|
|||||||
else:
|
else:
|
||||||
# Duplicate found
|
# Duplicate found
|
||||||
if seen[title] >= 1:
|
if seen[title] >= 1:
|
||||||
dupes.append([title, item._server.friendlyName])
|
|
||||||
# Go back through list to find original
|
# Go back through list to find original
|
||||||
for meta in meta_lst:
|
for meta in meta_lst:
|
||||||
if meta['title'] == title:
|
if meta['title'] == title:
|
||||||
|
Loading…
Reference in New Issue
Block a user