Adding allowRedirect for testing