-
Notifications
You must be signed in to change notification settings - Fork 22
Error running request({ uri: 'http:...' }).pipe(filed('/file')) #12
Copy link
Copy link
Open
Description
There are a couple of problems here:
- Since
self.methodis defined piping fails because the destination has no method .setHeader(). Looks like a miss on capability detection.
/a-project/node_modules/filed/main.js:87
self.dest.setHeader('content-type', self.mimetype)
^
TypeError: Cannot call method 'setHeader' of undefined
at /a-project/node_modules/filed/main.js:87:19
at Object.oncomplete (/a-project/node_modules/filed/main.js:152:7)
- Even if that is fixed since the request method is not
HEADit will attempt to pipe to an undefined destination:
stream.js:52
dest.on('drain', ondrain);
^
TypeError: Cannot call method 'on' of undefined
at [object Object].pipe (stream.js:52:8)
at /a-project/node_modules/filed/main.js:111:42
at Object.oncomplete (/a-project/node_modules/filed/main.js:154:7)
With both of those fixed I'm seeing empty files on disk. This may be a problem in some implementation on my end so I'm investigating further, but those two errors are definitely small bugs.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels