Include revision date in cipher requests (#1152)

Co-authored-by: Matt Gibson <mdgibson@Matts-MBP.lan>
This commit is contained in:
Matt Gibson 2020-11-23 14:41:43 -06:00 committed by GitHub
parent 405c4d1706
commit e27370cf32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View file

@ -3,6 +3,7 @@ using Bit.Core.Models.Api;
using Bit.Core.Models.Domain;
using System.Collections.Generic;
using System.Linq;
using System;
namespace Bit.Core.Models.Request
{
@ -16,6 +17,7 @@ namespace Bit.Core.Models.Request
Name = cipher.Name?.EncryptedString;
Notes = cipher.Notes?.EncryptedString;
Favorite = cipher.Favorite;
LastKnownRevisionDate = cipher.RevisionDate;
switch (Type)
{
@ -118,5 +120,6 @@ namespace Bit.Core.Models.Request
public List<PasswordHistoryRequest> PasswordHistory { get; set; }
public Dictionary<string, string> Attachments { get; set; }
public Dictionary<string, AttachmentRequest> Attachments2 { get; set; }
public DateTime LastKnownRevisionDate { get; set; }
}
}

View file

@ -176,7 +176,8 @@ namespace Bit.Core.Services
Favorite = model.Favorite,
OrganizationId = model.OrganizationId,
Type = model.Type,
CollectionIds = model.CollectionIds
CollectionIds = model.CollectionIds,
RevisionDate = model.RevisionDate
};
if (key == null && cipher.OrganizationId != null)