Fix bug where guardRoute cannot redirect to ''