Closed timcosta closed 5 years ago
With the current implementation an OPTIONS request with a missing or empty access-control-request-method header triggers a 500 error due to https://github.com/hapijs/hapi/blob/f02cdf14560a22c27dc0b59f3efa93dcf06b3ffa/lib/server.js#L345.
OPTIONS
access-control-request-method
This PR causes hapi-api-version to short circuit the call to server.match and responds with a 400.
hapi-api-version
server.match
With the current implementation an
OPTIONS
request with a missing or emptyaccess-control-request-method
header triggers a 500 error due to https://github.com/hapijs/hapi/blob/f02cdf14560a22c27dc0b59f3efa93dcf06b3ffa/lib/server.js#L345.This PR causes
hapi-api-version
to short circuit the call toserver.match
and responds with a 400.