mirror of
https://github.com/bitwarden/mobile
synced 2025-12-10 05:13:31 +00:00
* PM-4739 Implement checksum uri validation * PM-4739 Add missing field * PM-4739 Fix PR comments * PM-4739 Remove unnecessary comment * PM-4739 Add try catch and log exception * PM-4739 Added missing files from last commit * PM-4739 Change arg name * [PM-5461] Fix item saving with blank URI (#2948) * PM-5461 Fix item saving with blank URI * PM-5461 Fix PR comment
40 lines
917 B
C#
40 lines
917 B
C#
using Bit.Core.Enums;
|
|
using Bit.Core.Models.View;
|
|
|
|
namespace Bit.Core.Models.Export
|
|
{
|
|
public class LoginUri
|
|
{
|
|
public LoginUri() { }
|
|
|
|
public LoginUri(LoginUriView obj)
|
|
{
|
|
Match = obj.Match;
|
|
Uri = obj.Uri;
|
|
}
|
|
|
|
public LoginUri(Domain.LoginUri obj)
|
|
{
|
|
Match = obj.Match;
|
|
Uri = obj.Uri?.EncryptedString;
|
|
UriChecksum = obj.UriChecksum?.EncryptedString;
|
|
}
|
|
|
|
public UriMatchType? Match { get; set; }
|
|
public string Uri { get; set; }
|
|
public string UriChecksum { get; set; }
|
|
|
|
public static LoginUriView ToView(LoginUri req, LoginUriView view = null)
|
|
{
|
|
if (view == null)
|
|
{
|
|
view = new LoginUriView();
|
|
}
|
|
|
|
view.Match = req.Match;
|
|
view.Uri = req.Uri;
|
|
return view;
|
|
}
|
|
}
|
|
}
|