Skip to content

Commit

Permalink
v5.10.x Fix issue with saving data from POSTs
Browse files Browse the repository at this point in the history
  • Loading branch information
terrelsa13 committed Jan 3, 2025
1 parent c26e8dc commit 1e33ba9
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions mumc_modules/mumc_prepare_item.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def prepare_EPISODEoutput(the_dict,item,user_info,var_dict):
appendTo_DEBUG_log("\nitem['SeriesStudio'] Was Missing",3,the_dict)
if ((item['UserData']['Played'] == True) and (item['UserData']['PlayCount'] >= 1)):
if (not ('LastPlayedDate' in item['UserData'])):
if (episode_set_missing_last_played_date == 1):
if (episode_set_missing_last_played_date):
modify_lastPlayedDate(item,user_info['user_id'],the_dict)
else:
item['UserData']['LastPlayedDate']='1970-01-01T00:00:00.00Z'
Expand Down Expand Up @@ -190,8 +190,8 @@ def prepare_AUDIOoutput(the_dict,item,user_info,var_dict):
appendTo_DEBUG_log("\nitem['Studios']{'Name':'Unknown'} Was Missing",3,the_dict)
if ((item['UserData']['Played'] == True) and (item['UserData']['PlayCount'] >= 1)):
if (not ('LastPlayedDate' in item['UserData'])):
if (((mediaType == "audio") and (audio_set_missing_last_played_date == 1)) or
((isJellyfinServer(the_dict['server_brand'])) and (mediaType == "audiobook") and (audiobook_set_missing_last_played_date == 1))):
if (((mediaType == "audio") and audio_set_missing_last_played_date) or
((isJellyfinServer(the_dict['server_brand'])) and (mediaType == "audiobook") and audiobook_set_missing_last_played_date)):
modify_lastPlayedDate(item,user_info['user_id'],the_dict)
else:
item['UserData']['LastPlayedDate']='1970-01-01T00:00:00.00Z'
Expand Down
6 changes: 3 additions & 3 deletions mumc_modules/mumc_url.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,9 +231,9 @@ def requestURL(url, debugState, requestDebugMessage, retries, the_dict):
appendTo_DEBUG_log("\nResponse code: " + str(response.getcode()),2,the_dict)
if ((response.getcode() == 200) or (response.getcode() == 202)):
try:
if (url.method == 'GET'):
source = response.read()
data = json.loads(source)
source = response.read()
data = json.loads(source)
if ((url.method == 'GET')):
the_dict['cached_data'].addEntryToCache(url.full_url,data)
getdata = False
if (debugState):
Expand Down
2 changes: 1 addition & 1 deletion mumc_modules/mumc_versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

#Get the current script version
def get_script_version():
return '5.10.1-beta'
return '5.10.2'


#Get the min config version
Expand Down

0 comments on commit 1e33ba9

Please sign in to comment.