Fixes a minor problem on doing Oauth using JSON API.