Skip to content

Commit

Permalink
fix: Make sure we import path/fs only when really needed for object-c…
Browse files Browse the repository at this point in the history
…reation. Ensure we use agent-config plugin only in places it is needed
  • Loading branch information
nklomp committed Jun 15, 2024
1 parent 6611097 commit 76b4f53
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/agent-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"@types/url-parse": "^1.4.8",
"typescript": "5.4.2"
},
"peerDependencies": {},
"files": [
"dist/**/*",
"src/**/*",
Expand Down
2 changes: 1 addition & 1 deletion packages/agent-config/src/objectCreator.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { set, get } from 'jsonpointer'
import parse from 'url-parse'
import { resolve } from 'path'

/**
* Creates objects from a configuration object and a set of pointers.
Expand Down Expand Up @@ -94,6 +93,7 @@ export async function createObjects(config: object, pointers: Record<string, str
// console.log({module, member, type, query: parsed.query})

if (module.slice(0, 2) === './' || module.slice(0, 3) === '../') {
const { resolve } = await import('path')
module = resolve(module)
}

Expand Down
1 change: 1 addition & 0 deletions packages/vc-handler-ld-local/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
"@sphereon/isomorphic-webcrypto": "^2.4.1-unstable.0",
"@sphereon/ssi-sdk-ext.did-utils": "0.20.0",
"@sphereon/ssi-sdk-ext.key-utils": "0.20.0",
"@sphereon/ssi-sdk.agent-config": "workspace:*",
"@sphereon/ssi-sdk.core": "workspace:*",
"@sphereon/ssi-sdk.data-store": "workspace:*",
"@sphereon/ssi-sdk.vc-status-list": "workspace:*",
Expand Down
1 change: 1 addition & 0 deletions packages/vc-status-list-issuer-drivers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"@sphereon/ssi-sdk.core": "workspace:*",
"@sphereon/ssi-sdk.data-store": "workspace:*",
"@sphereon/ssi-sdk.vc-status-list": "workspace:*",
"@sphereon/ssi-sdk.agent-config": "workspace:*",
"@sphereon/ssi-types": "workspace:*",
"@sphereon/vc-status-list": "^7.0.0-next.0",
"@veramo/core": "4.2.0",
Expand Down

0 comments on commit 76b4f53

Please sign in to comment.