Skip to content

Commit

Permalink
fix(dialect): add missing assertion in createDialect
Browse files Browse the repository at this point in the history
  • Loading branch information
nomocas committed May 11, 2017
1 parent 066f6f7 commit 1635163
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lexicon/lexicon.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,9 @@ class Lexicon {
* @return {Lexicon} the new Lexicon that inherit from this one
*/
createDialect(name) {

assert(typeof name === 'string', 'lexicon.createDialect(...) need a string (the new lexicon name) as first argument');

return new Lexicon(name, this);
}
}
Expand Down

0 comments on commit 1635163

Please # to comment.