Skip to content

Commit

Permalink
fixup! chore(connect): remove DataManager dependency from DeviceList …
Browse files Browse the repository at this point in the history
…constructor
  • Loading branch information
mroz22 committed May 15, 2024
1 parent 497a80f commit f093d5e
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions packages/connect/src/device/DeviceList.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,21 @@ export class DeviceList extends TypedEmitter<DeviceListEvents> {
transportFirstEventPromise: Promise<void> | undefined;

constructor({
transports = ['BridgeTransport'],
debug = false,
transports,
debug,
messages,
}: {
transports?: ConnectSettings['transports'];
debug?: ConnectSettings['debug'];
messages: Record<string, any>;
}) {
super();
// we fill in `transports` with a reasonable fallback in src/index.
// since web index is released into npm, we can not rely
// on that that transports will be always set here. We need to provide a 'fallback of the last resort'
if (!transports?.length) {
transports = ['BridgeTransport'];
}

const transportLogger = initLog('@trezor/transport', debug);

Expand Down

0 comments on commit f093d5e

Please sign in to comment.