Support customizing the scope parameter when retrieving access token code.
pep8-ified the file.
Extracted GraphAPI exception logging into a method.
Redirect to login page instead of logging out.
Added tag keepsafe for changeset 04f0ec600875
Merged with mtr's changes.
Reintroduced check for uid in request.params to distinguish whether access token is valid or not.
Merged with Dag's latest changes.