decryptApiSecret method
Implementation
Future<String> decryptApiSecret(String apiHash) async {
ApiHashModel? model = await getApiModel(apiHash);
if (model == null) {
throw NoApiKeyFound();
}
String? decrypted = _encrypter.decrypt(model.apiSecretEncrypted);
if (decrypted == null) {
throw DecryptionException();
}
return decrypted;
}