Refatoring: Removed code duplication

In Resolver():

* Created _send_token_request() as it was used 3 times: PS: Should it be some other name instead?
* Removed redundant if statement that will result in the same return anyway.
Merge pull request #8291 from wari/patch-1

Refactoring: Removed code duplication