mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-08-19 21:03:21 -07:00
Catch null ratingKeys in plexWatch db importer.
Make sure we have a string when parsing the latinToAscii function.
This commit is contained in:
parent
776061605f
commit
a8236222fb
2 changed files with 15 additions and 8 deletions
|
@ -292,10 +292,15 @@ def import_from_plexwatch(database=None, table_name=None, import_ignore_interval
|
|||
|
||||
# If we get back None from our xml extractor skip over the record and log error.
|
||||
if not extracted_xml:
|
||||
logger.error(u"PlexPy Importer :: Skipping line with ratingKey %s due to malformed xml."
|
||||
logger.error(u"PlexPy Importer :: Skipping record with ratingKey %s due to malformed xml."
|
||||
% str(row['rating_key']))
|
||||
continue
|
||||
|
||||
# Skip line if we don't have a ratingKey to work with
|
||||
if not row['rating_key']:
|
||||
logger.error(u"PlexPy Importer :: Skipping record due to null ratingRey.")
|
||||
continue
|
||||
|
||||
# If the user_id no longer exists in the friends list, pull it from the xml.
|
||||
if user_data.get_user_id(user=row['user']):
|
||||
user_id = user_data.get_user_id(user=row['user'])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue