Fix for IE11 not supporting CustomEvent constructor