Fix to check before onebeforeunload