mirror of
https://github.com/bitwarden/android.git
synced 2024-11-01 15:45:42 +03:00
21 lines
460 B
C#
21 lines
460 B
C#
using System;
|
|
using Bit.App.Abstractions;
|
|
using Bit.App.Models;
|
|
using XLabs.Ioc;
|
|
|
|
namespace Bit.App
|
|
{
|
|
public static class Extentions
|
|
{
|
|
public static CipherString Encrypt(this string s)
|
|
{
|
|
if(s == null)
|
|
{
|
|
throw new ArgumentNullException(nameof(s));
|
|
}
|
|
|
|
var cryptoService = Resolver.Resolve<ICryptoService>();
|
|
return cryptoService.Encrypt(s);
|
|
}
|
|
}
|
|
}
|