silfverorg / duns.js

Javascript schema validator
5 stars 2 forks source link

Fixed bugg where schema.format did not use param. #43

Closed silfverstrom closed 9 years ago

silfverstrom commented 9 years ago

The following code did previously not work,

var schema = Duns.any().returns(function(num) {
  return num * 2;
});
schema.format(10); // Fails.

This was due to 'format' not accepting any params, and only using its bound value.

This PR closes #42.

silfverstrom commented 9 years ago

ping @br0r