Skip to content

Commit f6c6317

Browse files
authored
fix: reset timeout controller when messages are received (#474)
Otherwise all bitswap streams are closed after 30s
1 parent 40376cf commit f6c6317

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/network.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,9 @@ export class Network {
139139
this._bitswap._receiveError(err)
140140
break
141141
}
142+
143+
// we have received some data so reset the timeout controller
144+
controller.reset()
142145
}
143146
}
144147
)

0 commit comments

Comments
 (0)