Skip to content

Commit

Permalink
Fix build script (#27)
Browse files Browse the repository at this point in the history
The build script has been failing since `@metamask/post-message-stream`
was updated. This appears to be caused by the addition of modules to
that library that were meant to be used in the context of a Web Worker.
They referenced an import that only exists in a Web Worker context
(`worker_threads`). They were included in the main entrypoint for the
package, so browserify tried to walk the dependency graph and blew up
on that line.

The import has been updated to reference just the
`WindowPostMessageStream` module that is used, rather than the main
package entrypoint.
  • Loading branch information
Gudahtt authored Jul 12, 2022
1 parent 65a37e8 commit e9eddaf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import pump from 'pump';
import { WindowPostMessageStream } from '@metamask/post-message-stream';
import { WindowPostMessageStream } from '@metamask/post-message-stream/dist/window/WindowPostMessageStream';
import ObjectMultiplex from 'obj-multiplex';

const MAX = Number.MAX_SAFE_INTEGER;
Expand Down

0 comments on commit e9eddaf

Please sign in to comment.