1
0
mirror of https://github.com/bitwarden/server synced 2025-12-17 16:53:23 +00:00

[PM-22204] - update cipher/share endpoint to return revision date (#5900)

* return ciper response model in cipher share endpoint. add tests

* return dict instead of full cipher response. adjust specs

* rename vars

* rename vars

* rename vars

* reinsert braces

* add specs

* return CipherMiniResponseModel
This commit is contained in:
Jordan Aasen
2025-06-02 09:05:58 -07:00
committed by GitHub
parent 8c14630481
commit 2c4393cc16
4 changed files with 192 additions and 17 deletions

View File

@@ -628,7 +628,7 @@ public class CipherService : ICipherService
await _pushService.PushSyncCipherUpdateAsync(cipher, collectionIds);
}
public async Task ShareManyAsync(IEnumerable<(Cipher cipher, DateTime? lastKnownRevisionDate)> cipherInfos,
public async Task<IEnumerable<Cipher>> ShareManyAsync(IEnumerable<(Cipher cipher, DateTime? lastKnownRevisionDate)> cipherInfos,
Guid organizationId, IEnumerable<Guid> collectionIds, Guid sharingUserId)
{
var cipherIds = new List<Guid>();
@@ -655,6 +655,7 @@ public class CipherService : ICipherService
// push
await _pushService.PushSyncCiphersAsync(sharingUserId);
return cipherInfos.Select(c => c.cipher);
}
public async Task SaveCollectionsAsync(Cipher cipher, IEnumerable<Guid> collectionIds, Guid savingUserId,