Skip to content
This repository has been archived by the owner on Jan 28, 2024. It is now read-only.

Commit

Permalink
Merge 98e9064 into 6cf5d76
Browse files Browse the repository at this point in the history
  • Loading branch information
Fdawgs committed Dec 31, 2021
2 parents 6cf5d76 + 98e9064 commit 9b95316
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 9 deletions.
5 changes: 3 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,11 @@ Titles and headings should adhere to the [Associated Press (AP)](https://www.aps
Prior to submitting a pull request back to the main repository, please make sure you have completed the following steps:

1. Pull request base branch is set to `master`. All pull requests should be forked from and merged back to `master`
2. Run `npm test` to check the code adheres to the defined style and that it passes the Jest tests
2. Run `npm test` to check the code adheres to the defined ESLint style and that it passes the Jest tests
3. Run `npm run lint:prettier` to run the Prettier code formatter over the code
4. Run `npm run lint:licenses` if adding or updating production dependencies to check they use permissive licenses

Step 2. is automatically run by a pre-commit hook added by [Husky](https://typicode.github.io/husky/#/).
Steps 2. and 4. are automatically run by a pre-commit hook added by [Husky](https://typicode.github.io/husky/#/).

## Issues

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"jest": "jest --detectOpenHandles --runInBand",
"jest:coverage": "jest --coverage --runInBand",
"lint": "eslint . --cache --ext js,jsx,ts,tsx --ignore-path .gitignore",
"lint:licenses": "license-checker --direct --onlyAllow=\"0BSD;Apache-2.0;Apache 2.0;BSD-2-Clause;BSD-3-Clause;ISC;MIT;Unlicense\" --production --summary",
"lint:licenses": "license-checker --direct --onlyAllow=\"0BSD;Apache-2.0;BSD-2-Clause;BSD-3-Clause;ISC;MIT;Unlicense\" --production --summary",
"lint:prettier": "prettier . --write --ignore-unknown",
"lint:prettier:ci": "prettier . --check --ignore-unknown",
"prepare": "husky install && rm -rf .git/hooks && ln -s ../.husky .git/hooks",
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/jwt-jwks-auth/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ async function getSigningKey(token, jwksUri) {
* @author Frazer Smith
* @description Decorator plugin that adds `verifyJWT` function
* to authenticate JWTs using JWKS endpoint.
* @param {Function} server - Fastify instance.
* @param {object} server - Fastify instance.
* @param {object} options - Plugin config values.
* @param {string} options.jwksEndpoint - URL of endpoint containing JWKS public keys.
* @param {string|Array=} options.allowedAudiences - Accepted recipient(s) that JWT is intended for.
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/shared-schemas/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const S = require("fluent-json-schema");
/**
* @author Frazer Smith
* @description Plugin that adds collection of shared schemas for re-use throughout server.
* @param {Function} server - Fastify instance.
* @param {object} server - Fastify instance.
*/
async function plugin(server) {
// Response schemas
Expand Down
2 changes: 1 addition & 1 deletion src/routes/admin/healthcheck/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const { healthcheckGetSchema } = require("./schema");
* @description Sets routing options for server for healthcheck endpoint.
* This is used by monitoring software to poll and confirm the API is running,
* so needs no authentication.
* @param {Function} server - Fastify instance.
* @param {object} server - Fastify instance.
* @param {object} options - Route config values.
* @param {object} options.cors - CORS settings.
*/
Expand Down
2 changes: 1 addition & 1 deletion src/routes/redirect/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const { redirectGetSchema } = require("./schema");
/**
* @author Frazer Smith
* @description Sets routing options for server.
* @param {Function} server - Fastify instance.
* @param {object} server - Fastify instance.
* @param {object} options - Route config values.
* @param {object} options.cors - CORS settings.
* @param {string} options.redirectUrl - URL and port the Mirth Connect FHIR/HTTP Listener channel is listening on.
Expand Down
4 changes: 2 additions & 2 deletions src/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const sharedSchemas = require("./plugins/shared-schemas");
/**
* @author Frazer Smith
* @description Build Fastify instance.
* @param {Function} server - Fastify instance.
* @param {object} server - Fastify instance.
* @param {object} config - Fastify configuration values.
*/
async function plugin(server, config) {
Expand Down Expand Up @@ -55,7 +55,7 @@ async function plugin(server, config) {
.addHook("onSend", server.rateLimit())

/*
* `x-xss-protection` and `content-security-policy` is set by default.
* `x-xss-protection` and `content-security-policy` is set by default by Helmet.
* These are only useful for HTML/XML content; the only CSP directive that
* is of use to other content is "frame-ancestors 'none'" to stop responses
* from being wrapped in iframes and used for clickjacking attacks.
Expand Down

0 comments on commit 9b95316

Please sign in to comment.