Skip to content

Commit 7f64b8d

Browse files
committed
Add end == 0 handling for createReadStream
1 parent 187a7d5 commit 7f64b8d

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/clients/drive.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,7 @@ class RemoteHyperdrive {
249249

250250
req.setId(this.id)
251251
req.setPath(path)
252+
if (opts.end === 0) opts.length = 1
252253
if (opts.start) req.setStart(opts.start)
253254
if (opts.length) req.setLength(opts.length)
254255
if (opts.end) req.setEnd(opts.end)

0 commit comments

Comments
 (0)