update the oauth redirection to support either the redirect or iframe flow.