mirror of
https://github.com/bitwarden/mobile
synced 2025-12-10 13:23:39 +00:00
[PM-2713] make method async again
- returning null from a task thats not async throws
This commit is contained in:
@@ -625,13 +625,13 @@ namespace Bit.Core.Services
|
|||||||
encString.Iv, encString.Mac, key);
|
encString.Iv, encString.Mac, key);
|
||||||
}
|
}
|
||||||
|
|
||||||
public Task<EncString> EncryptAsync(string plainValue, SymmetricCryptoKey key = null)
|
public async Task<EncString> EncryptAsync(string plainValue, SymmetricCryptoKey key = null)
|
||||||
{
|
{
|
||||||
if (plainValue == null)
|
if (plainValue == null)
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
return EncryptAsync(Encoding.UTF8.GetBytes(plainValue), key);
|
return await EncryptAsync(Encoding.UTF8.GetBytes(plainValue), key);
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<EncString> EncryptAsync(byte[] plainValue, SymmetricCryptoKey key = null)
|
public async Task<EncString> EncryptAsync(byte[] plainValue, SymmetricCryptoKey key = null)
|
||||||
|
|||||||
Reference in New Issue
Block a user