diff --git a/src/assert.js b/src/assert.js index da6ea51..0ff0fa6 100644 --- a/src/assert.js +++ b/src/assert.js @@ -75,6 +75,10 @@ function prettyPrint(value) { function isType(value, T, errors) { + if (typeof value === 'undefined') { + return true; + } + if (T === primitives.void) { return typeof value === 'undefined'; }