Fix issues with OAuth