This commit is contained in:
syuilo 2018-11-04 23:13:35 +09:00
parent 1855ab60f1
commit 4f3c8b940e
No known key found for this signature in database
GPG key ID: BDC4C49D06AB9D69

View file

@ -40,7 +40,7 @@ function getParams<T extends IEndpointMeta>(defs: T, params: any): [Params<T>, E
(err as any).param = k;
return true;
} else {
if (v === undefined && def.default) {
if (v === undefined && def.hasOwnProperty('default')) {
x[k] = def.default;
} else {
x[k] = v;