Closed sgrove closed 7 years ago
This seems to have been fixed in webkit already: https://bugs.webkit.org/show_bug.cgi?id=168043
But I'd accept a PR that changes the default to an empty headersInit object. This might also be another case for writing functions that manually construct init objects instead of relying on the flawed bs.obj
which sets properties to undefined.
This should be fixed with https://github.com/BuckleScript/bucklescript/pull/1735
This will work fine in Chrome, but fail in Safari with
TypeError: undefined is not an object
(see https://github.com/zalando-incubator/atlas-js-core/pull/73 for the same issue in another project):(although obviously not until the request is fired)
Adding any sort of headers seems to fix the problem
At first glance, it seems like headers should default to an empty JS object or array when it's omitted in Reason code