fix rematch option

this.battle isn't available anymore after closing said battle, so the challenging should go before the closing