diff --git a/.changeset/quiet-falcons-press.md b/.changeset/quiet-falcons-press.md new file mode 100644 index 0000000000..37b2ab85a0 --- /dev/null +++ b/.changeset/quiet-falcons-press.md @@ -0,0 +1,5 @@ +--- +"medusa-telemetry": patch +--- + +Fix incorrect import diff --git a/packages/medusa-telemetry/src/store.js b/packages/medusa-telemetry/src/store.js index 90eeb2c538..4fe3e01065 100644 --- a/packages/medusa-telemetry/src/store.js +++ b/packages/medusa-telemetry/src/store.js @@ -1,16 +1,16 @@ -import path from "path" import Configstore from "configstore" +import path from "path" -import InMemConfig from "./util/in-memory-config" -import OutboxStore from "./util/outbox-store" +import { InMemoryConfigStore } from "./util/in-memory-config" import isTruthy from "./util/is-truthy" +import OutboxStore from "./util/outbox-store" class Store { constructor() { try { this.config_ = new Configstore(`medusa`, {}, { globalConfigPath: true }) } catch (e) { - this.config_ = new InMemConfig() + this.config_ = new InMemoryConfigStore() } const baseDir = path.dirname(this.config_.path) @@ -37,11 +37,11 @@ class Store { } async flushEvents(handler) { - return await this.outbox_.startFlushEvents(async eventData => { + return await this.outbox_.startFlushEvents(async (eventData) => { const events = eventData .split(`\n`) - .filter(e => e && e.length > 2) - .map(e => JSON.parse(e)) + .filter((e) => e && e.length > 2) + .map((e) => JSON.parse(e)) return await handler(events) })