updateToken method
Updates the token with the given json
and notifies all listeners
of the new token.
This method is used internally by getTokenResponse, but can also be used to update the token manually, e.g. when no refresh token is available and the token is updated by other means.
Implementation
void updateToken(Map<String, dynamic> json) {
_token =
TokenResponse.fromJson({'refresh_token': _token.refreshToken, ...json});
_onTokenChanged.add(_token);
}