Skip to content

Commit

Permalink
Merge pull request #283 from mdebarros/fix/#2436-SDK-Scheme-Adapter-I…
Browse files Browse the repository at this point in the history
…nbound-API-responds-incorrectly-for-'Unknown-URI'-Error-scenario

fix(mojaloop/#2436): sdk-sch-adapter inbound-api responds incorrectly for 'unknown uri' error scenario
- Fix for [mojaloop/#2436](mojaloop/project#2436) Inbound API Middleware for createHeaderValidator function would continue validating even if the resource was invalid, thereby replacing the Interface OpenAPI Validation of the createRequestValidator Middleware.
  • Loading branch information
mdebarros authored Aug 27, 2021
2 parents 151aaae + b5d7dea commit d53fb2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/InboundServer/middlewares.js
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ const createHeaderValidator = (logger) => async (

// Only validate requests for the requested resources
if (!resources.includes(resource)) {
await next();
return await next();
}

// Always validate the accept header for a get request, or optionally if it has been
Expand Down

0 comments on commit d53fb2c

Please sign in to comment.