From 754f7259e0ad08141cbe6a6bd0d75446b199395d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCrg=C3=BCn=20Day=C4=B1o=C4=9Flu?= Date: Sun, 25 Feb 2024 12:11:14 +0100 Subject: [PATCH 1/5] update for v5 --- .github/workflows/ci.yml | 2 +- index.js | 2 +- package.json | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7b00276..5395d92 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,7 +17,7 @@ on: jobs: test: - uses: fastify/workflows/.github/workflows/plugins-ci.yml@v3 + uses: fastify/workflows/.github/workflows/plugins-ci.yml@v4.1.0 with: license-check: true lint: true diff --git a/index.js b/index.js index 7798845..b20a1f9 100644 --- a/index.js +++ b/index.js @@ -8,7 +8,7 @@ function Negotiator (options) { const { supportedValues = [], cache - } = (options && typeof options === 'object' && options) || {} + } = (typeof options === 'object' && options) || {} this.supportedValues = supportedValues diff --git a/package.json b/package.json index 35e86c4..f634735 100644 --- a/package.json +++ b/package.json @@ -35,8 +35,8 @@ "devDependencies": { "benchmark": "2.1.4", "standard": "17.1.0", - "tap": "^16.3.0", - "tsd": "^0.30.0" + "tap": "^18.7.0", + "tsd": "^0.30.7" }, "engines": { "node": ">=14" From cd6d7e5d2688474e4c59faecdcfafc0ceffde597 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCrg=C3=BCn=20Day=C4=B1o=C4=9Flu?= Date: Sun, 25 Feb 2024 12:11:32 +0100 Subject: [PATCH 2/5] add pre-commit --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index f634735..256279d 100644 --- a/package.json +++ b/package.json @@ -33,6 +33,7 @@ "author": "Aras Abbasi", "license": "MIT", "devDependencies": { + "@fastify/pre-commit": "^2.1.0", "benchmark": "2.1.4", "standard": "17.1.0", "tap": "^18.7.0", From 38daa5cc2e0afe287fb4e4d1339aabddc3d05054 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCrg=C3=BCn=20Day=C4=B1o=C4=9Flu?= Date: Sun, 25 Feb 2024 12:15:53 +0100 Subject: [PATCH 3/5] package-manager v4 --- .github/workflows/package-manager-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/package-manager-ci.yml b/.github/workflows/package-manager-ci.yml index 89d450f..113aad3 100644 --- a/.github/workflows/package-manager-ci.yml +++ b/.github/workflows/package-manager-ci.yml @@ -17,4 +17,4 @@ on: jobs: test: - uses: fastify/workflows/.github/workflows/plugins-ci-package-manager.yml@v3 + uses: fastify/workflows/.github/workflows/plugins-ci-package-manager.yml@v4.1.0 From f8bd4ec1d889570a59d17cd70e8b85a87351abcd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCrg=C3=BCn=20Day=C4=B1o=C4=9Flu?= Date: Sun, 25 Feb 2024 12:20:06 +0100 Subject: [PATCH 4/5] revert change --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index b20a1f9..7798845 100644 --- a/index.js +++ b/index.js @@ -8,7 +8,7 @@ function Negotiator (options) { const { supportedValues = [], cache - } = (typeof options === 'object' && options) || {} + } = (options && typeof options === 'object' && options) || {} this.supportedValues = supportedValues From 8d1bac460881d5b841f968620bd5315d293fb389 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCrg=C3=BCn=20Day=C4=B1o=C4=9Flu?= Date: Sun, 25 Feb 2024 12:33:07 +0100 Subject: [PATCH 5/5] remove engines field --- package.json | 3 --- 1 file changed, 3 deletions(-) diff --git a/package.json b/package.json index 256279d..6ee5ebf 100644 --- a/package.json +++ b/package.json @@ -39,9 +39,6 @@ "tap": "^18.7.0", "tsd": "^0.30.7" }, - "engines": { - "node": ">=14" - }, "repository": { "type": "git", "url": "git+https://github.com/fastify/accept-negotiator.git"