Skip to content

Commit

Permalink
Fixed max schema length comparison check
Browse files Browse the repository at this point in the history
  • Loading branch information
timgit committed Mar 3, 2017
1 parent 13024f0 commit 62be625
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/attorney.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function checkConfig(config) {

if(config.schema){
assert(typeof config.schema == 'string', 'configuration assert: schema must be a string');
assert(config.schema.length < 50, 'configuration assert: schema should be between 1 and 50 characters');
assert(config.schema.length <= 50, 'configuration assert: schema should be between 1 and 50 characters');
assert(!/\W/.test(config.schema), `configuration assert: ${config.schema} cannot be used as a schema. Only alphanumeric characters and underscores are allowed`);
}

Expand Down

0 comments on commit 62be625

Please sign in to comment.