diff --git a/plexpy/libraries.py b/plexpy/libraries.py index 79e520ba..1cdf54b0 100644 --- a/plexpy/libraries.py +++ b/plexpy/libraries.py @@ -1040,7 +1040,8 @@ class Libraries(object): purge_only=purge_only)) return all(success) - elif server_id and str(section_id).isdigit(): + elif str(section_id).isdigit(): + server_id = server_id or plexpy.CONFIG.PMS_IDENTIFIER database.delete_library_history(server_id=server_id, section_id=section_id) if purge_only: return True diff --git a/plexpy/users.py b/plexpy/users.py index cf61db0c..55f04c19 100644 --- a/plexpy/users.py +++ b/plexpy/users.py @@ -676,7 +676,8 @@ class Users(object): success = [] for user in result: - success.append(self.delete(user_id=user['user_id'], purge_only=purge_only)) + success.append(self.delete(user_id=user['user_id'], + purge_only=purge_only)) return all(success) elif str(user_id).isdigit(): diff --git a/plexpy/webserve.py b/plexpy/webserve.py index 6292e1fa..7389ceaa 100644 --- a/plexpy/webserve.py +++ b/plexpy/webserve.py @@ -915,10 +915,10 @@ class WebInterface(object): ``` Required parameters: - server_id (str): The Plex server identifier of the library section section_id (str): The id of the Plex library section Optional parameters: + server_id (str): The Plex server identifier of the library section row_ids (str): Comma separated row ids to delete, e.g. "2,3,8" Returns: @@ -944,10 +944,10 @@ class WebInterface(object): ``` Required parameters: - server_id (str): The Plex server identifier of the library section section_id (str): The id of the Plex library section Optional parameters: + server_id (str): The Plex server identifier of the library section row_ids (str): Comma separated row ids to delete, e.g. "2,3,8" Returns: