-
Notifications
You must be signed in to change notification settings - Fork 70
Closed
Labels
type/bugSomething isn't workingSomething isn't working
Description
When using HttpEmitter.send() method, how can I pass additional header arguments (e.g. meant for our infrastructure) that are passed through to the http.request() call?
I tried to use
const emitter = new HTTPEmitter({
url: "https://foo.bar"
})
const event = ...
emitter.send(event, {
headers: {
customheader: "...",
authorization: "Bearer ...."
}
})
When debugging, it seemed like the passed headers are overwritten by the default headers.
const config = { ...options, ...defaults }; |
translated to
const config = Object.assign(Object.assign({}, options), defaults);
Metadata
Metadata
Assignees
Labels
type/bugSomething isn't workingSomething isn't working