diff --git a/plexpy/notification_handler.py b/plexpy/notification_handler.py index 0fb7d7d0..0a5b25d8 100644 --- a/plexpy/notification_handler.py +++ b/plexpy/notification_handler.py @@ -709,7 +709,7 @@ def build_media_notify_params(notify_action=None, session=None, timeline=None, m 'server_machine_id': plexpy.CONFIG.PMS_IDENTIFIER, 'server_platform': plexpy.CONFIG.PMS_PLATFORM, 'server_version': plexpy.CONFIG.PMS_VERSION, - 'action': notify_action.lstrip('on_'), + 'action': notify_action.split('on_')[-1], 'week_number': arrow.now().isocalendar()[1], 'datestamp': arrow.now().format(date_format), 'timestamp': arrow.now().format(time_format), @@ -914,7 +914,7 @@ def build_server_notify_params(notify_action=None, **kwargs): 'server_platform': plexpy.CONFIG.PMS_PLATFORM, 'server_version': plexpy.CONFIG.PMS_VERSION, 'server_machine_id': plexpy.CONFIG.PMS_IDENTIFIER, - 'action': notify_action.lstrip('on_'), + 'action': notify_action.split('on_')[-1], 'datestamp': arrow.now().format(date_format), 'timestamp': arrow.now().format(time_format), 'unixtime': int(time.time()),