Use cloned unhandledReasons array

This allows it be inspected in the dev tools even after
it has been modified.