Skip to content
This repository was archived by the owner on Feb 10, 2024. It is now read-only.

Commit 9dd79e6

Browse files
authored
Merge pull request #236 from inetzo/patch-1
Null-check for err object when submiting
2 parents 93b53a2 + f3a91fa commit 9dd79e6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Our.Umbraco.DocTypeGridEditor/Web/UI/App_Plugins/DocTypeGridEditor/Js/doctypegrideditor.controllers.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,9 @@ angular.module("umbraco").controller("Our.Umbraco.DocTypeGridEditor.Dialogs.DocT
297297
// Set original value of $routeParams.create
298298
$routeParams.create = routeParamsCreate;
299299
// cleanup the blueprint immediately
300-
$scope.model.node.id = err.data.id;
300+
if (err && err.data) {
301+
$scope.model.node.id = err.data.id;
302+
}
301303
cleanup();
302304
vm.saveButtonState = "error";
303305
});

0 commit comments

Comments
 (0)