Fix: Form is initially not available in $scope.

This commit is contained in:
Your Name 2014-06-09 20:30:01 +02:00
parent 1aba5ccd2e
commit 79fe5b8612

View file

@ -81,8 +81,7 @@ angular.module('ffffng')
var submitted = false; var submitted = false;
$scope.hasError = function (field) { $scope.hasError = function (field) {
var input = $scope.nodeForm[field]; return $scope.nodeForm && $scope.nodeForm[field].$invalid && submitted;
return input.$invalid && submitted;
}; };
var duplicateError = { var duplicateError = {