invalidate function
Invalidates the accessToken of given mojangAccount
.
Implementation
Future<bool> invalidate(MojangAccount mojangAccount) async {
final payload = {
'accessToken': mojangAccount.accessToken,
'clientToken': mojangAccount.clientToken,
};
final response = await requestBody(
http.post, _authServerApi, 'invalidate', payload,
headers: {});
final data = parseResponseMap(response);
return data.isEmpty;
}