From ff9932b2f38d4e64de15937bcc410bc664d945f3 Mon Sep 17 00:00:00 2001 From: Daniel Salazar Date: Tue, 28 Oct 2025 13:04:54 -0700 Subject: [PATCH] fix: dbkv raw import (#1848) --- eslint.config.js | 16 ++++++++++++++-- extensions/api.d.ts | 11 ++++------- .../services/repositories/DBKVStore/index.mjs | 2 +- 3 files changed, 19 insertions(+), 10 deletions(-) diff --git a/eslint.config.js b/eslint.config.js index 3a654acc0..82154ba40 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -110,7 +110,13 @@ export default defineConfig([ 'src/backend/**/*.{js,mjs,cjs,ts}', 'extensions/**/*.{js,mjs,cjs,ts}', ], - languageOptions: { globals: globals.browser }, + languageOptions: { + globals: { + ...globals.browser, + ...globals.jquery, + i18n: 'readonly', + }, + }, rules: { 'no-unused-vars': ['error', { @@ -157,7 +163,13 @@ export default defineConfig([ { files: ['**/*.{js,mjs,cjs,ts}'], ignores: ['src/backend/**/*.{js,mjs,cjs,ts}'], - languageOptions: { globals: globals.browser }, + languageOptions: { + globals: { + ...globals.browser, + ...globals.jquery, + i18n: 'readonly', + }, + }, rules: { 'no-unused-vars': ['error', { 'vars': 'all', diff --git a/extensions/api.d.ts b/extensions/api.d.ts index fd4adf398..f3ac6c0f3 100644 --- a/extensions/api.d.ts +++ b/extensions/api.d.ts @@ -4,11 +4,8 @@ import type { MeteringServiceWrapper } from '@heyputer/backend/src/services/Mete import type { DBKVStore } from '@heyputer/backend/src/services/repositories/DBKVStore/DBKVStore.ts'; import type { SUService } from '@heyputer/backend/src/services/SUService.js'; import type { RequestHandler } from 'express'; -import type helpers from '../src/backend/src/helpers.js'; import type FSNodeContext from '../src/backend/src/filesystem/FSNodeContext.js'; -import type selectors from '../src/backend/src/filesystem/node/selectors.js'; - -export type FSNodeContext = FSNodeContext; +import type helpers from '../src/backend/src/helpers.js'; declare global { namespace Express { @@ -42,9 +39,9 @@ interface CoreRuntimeModule { } } -type FilesystemModule = { - FSNodeContext: FSNodeContext, - selectors: selectors, +interface FilesystemModule { + FSNodeContext: FSNodeContext, + selectors: unknown, } type StripPrefix = T extends `${TPrefix}.${infer R}` ? R : never; diff --git a/src/backend/src/services/repositories/DBKVStore/index.mjs b/src/backend/src/services/repositories/DBKVStore/index.mjs index 7a693418b..ce54b7672 100644 --- a/src/backend/src/services/repositories/DBKVStore/index.mjs +++ b/src/backend/src/services/repositories/DBKVStore/index.mjs @@ -13,7 +13,7 @@ export class DBKVServiceWrapper extends BaseService { }); Object.getOwnPropertyNames(DBKVStore.prototype).forEach(fn => { if ( fn === 'constructor' ) return; - this[fn] = (...args) => this.kvStore[fn](args); + this[fn] = (...args) => this.kvStore[fn](...args); }); } static IMPLEMENTS = {