When switching between staging and production environments, authentication fails in staging but works in prod.