Skip to content

Commit

Permalink
refactor: remove extra ?. operator
Browse files Browse the repository at this point in the history
  • Loading branch information
c0sx committed Sep 22, 2024
1 parent 9d6a8cf commit a31eb9a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ async function fastifyUnderPressure (fastify, opts) {
}

function onRequest (req, reply, next) {
const config = req?.routeOptions?.config ?? req.context.config
const config = req.routeOptions?.config ?? req.context.config
const _pressureHandler = config.pressureHandler || pressureHandler
if (checkMaxEventLoopDelay && eventLoopDelay > maxEventLoopDelay) {
handlePressure(_pressureHandler, req, reply, next, TYPE_EVENT_LOOP_DELAY, eventLoopDelay)
Expand Down

0 comments on commit a31eb9a

Please sign in to comment.