From 45d4bd75bb3bea6c0861a08f8b00fd825f5b809b Mon Sep 17 00:00:00 2001 From: "Mike P. Sinn" Date: Tue, 22 Sep 2020 16:29:48 -0500 Subject: [PATCH] Handle no response --- src/js/qmHelpers.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/js/qmHelpers.js b/src/js/qmHelpers.js index 0d9be39f65..ed8b0eaba8 100644 --- a/src/js/qmHelpers.js +++ b/src/js/qmHelpers.js @@ -5829,6 +5829,15 @@ var qm = { }) qm.api.postToQuantiModo(body, 'v3/trackingReminderNotifications', function(response){ + if(!response){ + var err = "No response from postToQuantiModo(body, 'v3/trackingReminderNotifications"; + if(errorHandler){ + errorHandler(err); + return; + } else { + throw err; + } + } var measurements = response.measurements || response.data.measurements; if(measurements){qm.measurements.addMeasurementsToMemory(measurements);} var trackingReminderNotifications = response.trackingReminderNotifications || response.data.trackingReminderNotifications;