Skip to content

Commit

Permalink
Merge pull request #290 from dastiw1/master
Browse files Browse the repository at this point in the history
fix custom field error
  • Loading branch information
icebob authored Sep 15, 2017
2 parents abc6c43 + 58bbe06 commit 5099907
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ module.exports.slugifyFormID = function(schema, prefix = "") {
return prefix + schema.id;
} else {
// Return the slugified version of either:
return prefix + (schema.inputName || schema.label || schema.model)
return prefix + (schema.inputName || schema.label || schema.model || "")
// NB: This is a very simple, conservative, slugify function,
// avoiding extra dependencies.
.toString()
Expand All @@ -77,4 +77,4 @@ module.exports.slugifyFormID = function(schema, prefix = "") {
// Remove anything that isn't a (English/ASCII) letter, number or dash.
.replace(/([^a-zA-Z0-9-]+)/g, "");
}
};
};

0 comments on commit 5099907

Please sign in to comment.