Skip to content

Commit 586bbb8

Browse files
toger5robintown
andcommitted
Update src/UrlParams.ts
Co-authored-by: Robin <robin@robin.town>
1 parent 4a9e970 commit 586bbb8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/UrlParams.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ class ParamParser {
263263
type: { [s: string]: T } | ArrayLike<T>,
264264
): T | undefined {
265265
const value = this.getParam(name);
266-
if (value && Object.values(type).includes(value as T)) {
266+
if (value !== null && Object.values(type).includes(value as T)) {
267267
return value as T;
268268
}
269269
return undefined;

0 commit comments

Comments
 (0)