From b26990a875914d97688f5f3d13c38f9f90619b4d Mon Sep 17 00:00:00 2001 From: Julien Herr Date: Thu, 21 May 2026 12:09:26 +0200 Subject: [PATCH] fix: address PR review comments - Fix KV json overload to return Promise (null on missing keys) - Add shebang to Husky pre-commit hook - Explicitly add eslint ^10.0.0 to devDependencies Co-Authored-By: Claude Sonnet 4.6 --- .husky/pre-commit | 1 + package.json | 1 + src/types/index.ts | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.husky/pre-commit b/.husky/pre-commit index 57fb103..1ac5081 100644 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1 +1,2 @@ +#!/bin/sh npx lint-staged && npm run typecheck && npm test diff --git a/package.json b/package.json index 3240bcb..df540a9 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ "@types/mailparser": "^3.4.6", "@types/rss": "^0.0.32", "@vitest/coverage-v8": "^4.0.18", + "eslint": "^10.0.0", "eslint-config-prettier": "^10.1.8", "happy-dom": "^20.5.0", "husky": "^9.1.7", diff --git a/src/types/index.ts b/src/types/index.ts index 7bc7b86..92f2a08 100644 --- a/src/types/index.ts +++ b/src/types/index.ts @@ -71,7 +71,7 @@ declare global { // This is not an ideal solution but works for our example interface KVNamespace { get(key: string, options?: { type: "text" }): Promise; - get(key: string, options: { type: "json" }): Promise; + get(key: string, options: { type: "json" }): Promise; get( key: string, options: { type: "arrayBuffer" },