When run inside a WebWorker, it throws "global is not defined", since both the window & global object do not exist.