Skip to content

Commit

Permalink
try catch on default value populate
Browse files Browse the repository at this point in the history
  • Loading branch information
yurikuzn committed Feb 20, 2020
1 parent b2e1ff0 commit 1dbc416
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions client/src/model.js
Expand Up @@ -103,8 +103,12 @@ define('model', [], function () {
var defaultValue = this.getFieldParam(field, 'default');

if (defaultValue != null) {
var defaultValue = this.parseDefaultValue(defaultValue);
defaultHash[field] = defaultValue;
try {
var defaultValue = this.parseDefaultValue(defaultValue);
defaultHash[field] = defaultValue;
} catch (e) {
console.error(e);
}
}

var defaultAttributes = this.getFieldParam(field, 'defaultAttributes');
Expand Down

0 comments on commit 1dbc416

Please sign in to comment.