Skip to content

Commit

Permalink
update npm dependency to [email protected].
Browse files Browse the repository at this point in the history
  • Loading branch information
xicilion committed Jul 10, 2024
1 parent 81a47e1 commit 07692f0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
3 changes: 2 additions & 1 deletion packages/orm/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@fxjs/orm",
"version": "1.16.9",
"version": "1.16.10",
"description": "",
"main": "lib",
"types": "typings/index.d.ts",
Expand Down Expand Up @@ -42,6 +42,7 @@
"@fxjs/sql-query": "^0.10.1",
"@types/knex": "^0.16.1",
"fib-pool": "^1.6.0",
"fib-cache": "^1.1.0",
"knex": "^2.5.1",
"lodash.clonedeep": "^4.5.0",
"lodash.flatten": "^4.4.0",
Expand Down
9 changes: 5 additions & 4 deletions packages/orm/src/Model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import { FxOrmSqlDDLSync } from '@fxjs/sql-ddl-sync';
import { FxOrmDMLDriver } from './Typo/DMLDriver';
import { FxOrmError } from './Typo/Error';
import { FxOrmQuery } from './Typo/query';
const fc = require('fib-cache');

import type {
FxSqlQuerySubQuery,
Expand Down Expand Up @@ -229,10 +230,10 @@ export const Model = function (
Utilities.addUnwritableProperty(model, 'properties', m_opts.properties, { configurable: false })
Utilities.addUnwritableProperty(model, 'settings', m_opts.settings, { configurable: false })
Utilities.addUnwritableProperty(model, 'keys', m_opts.keys, { configurable: false })
Utilities.addUnwritableProperty(model, 'caches', new util.LruCache(
m_opts.instanceCacheSize > 0 && Number.isInteger(m_opts.instanceCacheSize) ? m_opts.instanceCacheSize : m_opts.settings.get('instance.defaultCacheSize'),
(typeof m_opts.identityCache === 'number' ? m_opts.identityCache : 1) * 1000
), { configurable: false })
Utilities.addUnwritableProperty(model, 'caches', new fc.LRU({
max: m_opts.instanceCacheSize > 0 && Number.isInteger(m_opts.instanceCacheSize) ? m_opts.instanceCacheSize : m_opts.settings.get('instance.defaultCacheSize'),
ttl: (typeof m_opts.identityCache === 'number' ? m_opts.identityCache : 1) * 1000
}), { configurable: false })

model.dropSync = function (
this: FxOrmModel.Model,
Expand Down

0 comments on commit 07692f0

Please sign in to comment.