Skip to content

Commit ecd89ce

Browse files
authored
fix #917 getQuery(key) typings (#941)
1 parent f2c021f commit ecd89ce

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎docs/index.d.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,8 +216,8 @@ export interface HttpRequest {
216216
getCaseSensitiveMethod() : string;
217217
/** Returns the raw querystring (the part of URL after ? sign) or empty string. */
218218
getQuery() : string;
219-
/** Returns a decoded query parameter value or empty string. */
220-
getQuery(key: string) : string;
219+
/** Returns a decoded query parameter value or undefined. */
220+
getQuery(key: string) : string | undefined;
221221
/** Loops over all headers. */
222222
forEach(cb: (key: string, value: string) => void) : void;
223223
/** Setting yield to true is to say that this route handler did not handle the route, causing the router to continue looking for a matching route handler, or fail. */

0 commit comments

Comments
 (0)