hiidef/oauth2app — pull request #22 by ckelly (2012-04-16 05:38:04+00:00)
Title: Fix issue when requesting token with grant_type client_credentials

Came across an issue when requesting a token using the client_credentials grant_type.

Offending code was token.py, _get_client_credentials_token, line 412

Exception was "NoneType has no attribute "scope". Turns out when using client_credentials, the code was creating a new access_token object, but was trying to assign to self.access_token instead of the newly created in-scope object. I removed the references to self in the code.

Verified with new unit test GrantTypeTestCase.test_00_grant_type_client_credentials