Sync response can be null

This commit is contained in:
Mo Bitar
2018-07-16 13:37:13 -05:00
parent 0f74458fd2
commit a699fc0cb7
2 changed files with 2 additions and 2 deletions

View File

@@ -491,7 +491,7 @@ class ComponentManager {
// Allow handlers to be notified when a save begins and ends, to update the UI
var saveMessage = Object.assign({}, message);
saveMessage.action = response && response.error ? "save-error" : "save-success";
this.replyToMessage(component, message, {error: response.error})
this.replyToMessage(component, message, {error: response && response.error})
this.handleMessage(component, saveMessage);
});
});