I am currently experimenting with workers.
What I want to do is to fetch a remote url, change the headers, and return it. Since headers of responses are immutable, I have to read the body of the response and create a new response. Since the response is not regular text I use the following method to fetch the content:
When I try to test a URL in the workers editor I receive:
Uncaught (in promise) Error: internal error. When I visit the same url via the browser, it works. This seems quite unexpected to me. Has anyone else seen this or an idea what might happen?