Fix isHTTPMethod validator

This commit is contained in:
Garrett Mills 2022-11-14 21:48:28 -06:00
parent bbf2807cfa
commit 37fcaabdef
2 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
{
"name": "@extollo/lib",
"version": "0.14.9",
"version": "0.14.10",
"description": "The framework library that lifts up your code.",
"main": "lib/index.js",
"types": "lib/index.d.ts",

View File

@ -20,7 +20,7 @@ export type HTTPMethod = 'post' | 'get' | 'patch' | 'put' | 'delete' | 'options'
* @param what
*/
export function isHTTPMethod(what: unknown): what is HTTPMethod {
return ['post', 'get', 'patch', 'put', 'delete'].includes(String(what))
return ['post', 'get', 'patch', 'put', 'delete', 'options'].includes(String(what))
}
/**