mirror of
https://github.com/bitwarden/server.git
synced 2025-07-01 08:02:49 -05:00
react to contact changes not being set from identity
This commit is contained in:
@ -33,12 +33,12 @@ namespace Bit.Api.Models
|
||||
[StringLength(10000)]
|
||||
public string Notes { get; set; }
|
||||
|
||||
public virtual Cipher ToCipher(string userId = null)
|
||||
public virtual Cipher ToCipher(Guid userId)
|
||||
{
|
||||
var cipher = new Cipher
|
||||
{
|
||||
Id = new Guid(Id),
|
||||
UserId = new Guid(userId),
|
||||
UserId = userId,
|
||||
FolderId = string.IsNullOrWhiteSpace(FolderId) ? null : (Guid?)new Guid(FolderId),
|
||||
Type = Type
|
||||
};
|
||||
|
@ -19,11 +19,11 @@ namespace Bit.Api.Models
|
||||
[StringLength(255)]
|
||||
public string PushToken { get; set; }
|
||||
|
||||
public Device ToDevice(string userId = null)
|
||||
public Device ToDevice(Guid? userId = null)
|
||||
{
|
||||
return ToDevice(new Device
|
||||
{
|
||||
UserId = userId == null ? default(Guid) : new Guid(userId)
|
||||
UserId = userId == null ? default(Guid) : userId.Value
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -13,11 +13,11 @@ namespace Bit.Api.Models
|
||||
[StringLength(300)]
|
||||
public string Name { get; set; }
|
||||
|
||||
public Cipher ToCipher(string userId = null)
|
||||
public Cipher ToCipher(Guid userId)
|
||||
{
|
||||
return ToCipher(new Cipher
|
||||
{
|
||||
UserId = new Guid(userId)
|
||||
UserId = userId
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -28,11 +28,11 @@ namespace Bit.Api.Models
|
||||
[StringLength(10000)]
|
||||
public string Notes { get; set; }
|
||||
|
||||
public Cipher ToCipher(string userId = null)
|
||||
public Cipher ToCipher(Guid userId)
|
||||
{
|
||||
return ToCipher(new Cipher
|
||||
{
|
||||
UserId = new Guid(userId)
|
||||
UserId = userId
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user