[Create] Add specificity to check

Explicitly check if an object has a persistence timestamp
at all (avoids false-positives due to falsiness of zero.)
This commit is contained in:
Victor Woeltjen 2016-02-10 12:07:45 -08:00
parent 88750d92ef
commit c43929f1c6
2 changed files with 1 additions and 5 deletions

View File

@ -156,11 +156,7 @@ define([
"name": "Save",
"description": "Save changes made to these objects.",
"depends": [
"$q",
"$location",
"$injector",
"urlService",
"navigationService",
"policyService",
"dialogService",
"creationService",

View File

@ -118,7 +118,7 @@ define(
function doSave() {
//This is a new 'virtual object' that has not been persisted
// yet.
if (!domainObject.getModel().persisted){
if (domainObject.getModel().persisted === undefined){
return getParent(domainObject)
.then(doWizardSave)
.then(getParent)