From e03389909e84aa361db14711efe4bdf0c4bb2cab Mon Sep 17 00:00:00 2001 From: Nuwan Date: Thu, 20 Jul 2023 03:31:37 +0530 Subject: [PATCH] fix showing error alert on audio resync --- .../stores/SessionStore.js.coffee | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/web/app/assets/javascripts/react-components/stores/SessionStore.js.coffee b/web/app/assets/javascripts/react-components/stores/SessionStore.js.coffee index f462f79fa..1fedebdf6 100644 --- a/web/app/assets/javascripts/react-components/stores/SessionStore.js.coffee +++ b/web/app/assets/javascripts/react-components/stores/SessionStore.js.coffee @@ -278,11 +278,18 @@ ConfigureTracksActions = @ConfigureTracksActions onAudioResync: `async function() { logger.debug("audio resyncing"); - const response = await context.jamClient.SessionAudioResync(); - if (response != null) { - return this.app.notify({ + try{ + const response = await context.jamClient.SessionAudioResync(); + if(!response.process_status === 'Success') { + this.app.notify({ + "title": "Error", + "text": 'Error in audio resyncing', + "icon_url": "/assets/content/icon_alert_big.png"}); + } + }catch(e){ + this.app.notify({ "title": "Error", - "text": response, + "text": e.message, "icon_url": "/assets/content/icon_alert_big.png"}); } }`