Cleanup, refactor; Chrome is throwing an ex

but Webstorm runs fine.