Ensure variable exists before calling toString on it to fix js error thrown when creating grafana notification

This commit is contained in:
mabashian 2019-07-31 14:15:13 -04:00
parent 4a35df9a1c
commit 94b5bb8cf9

View File

@ -199,7 +199,7 @@ export default ['Rest', 'Wait', 'NotificationsFormObject',
$scope[i] = null;
}
else {
$scope[i] = $scope[i].toString().split('\n');
$scope[i] = $scope[i] ? $scope[i].toString().split('\n') : "";
}
}
if (field.type === 'checkbox') {