The point of this function is to be able to prevent only the first `hashchange` event when `this.allowHashchange = false`, and then reset that value such that all subsequent `hashchange` events are allowed. I don't know if there is a better way! Maybe the function name should be changed?