Skip to content

Commit 22e0b90

Browse files
pfrazeeandrewosh
authored andcommitted
Check fuse exists before attaching event
1 parent 33a8366 commit 22e0b90

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ class HyperdriveDaemon extends EventEmitter {
9292
this.drives = new DriveManager(this.corestore, this.networking, dbs.drives, this.opts)
9393
this.fuse = hyperfuse ? new FuseManager(this.drives, dbs.fuse, this.opts) : null
9494
this.drives.on('error', err => this.emit('error', err))
95-
this.fuse.on('error', err => this.emit('error', err))
95+
if (this.fuse) this.fuse.on('error', err => this.emit('error', err))
9696

9797
await Promise.all([
9898
this.drives.ready(),

0 commit comments

Comments
 (0)