mirror of
https://github.com/bitwarden/server.git
synced 2025-07-02 16:42:50 -05:00
Resolve Vault and DB Warnings (#4646)
* Resolve Vault Warnings * Resolve DB Warnings
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
#nullable enable
|
||||
using System.Diagnostics;
|
||||
using Bit.Core.Context;
|
||||
using Bit.Core.Entities;
|
||||
using Bit.Core.Enums;
|
||||
@ -98,6 +99,12 @@ public class BulkCollectionAuthorizationHandler : BulkAuthorizationHandler<BulkC
|
||||
case not null when requirement == BulkCollectionOperations.Delete:
|
||||
authorized = await CanDeleteAsync(resources, org);
|
||||
break;
|
||||
|
||||
case null:
|
||||
// requirement isn't actually nullable but since we use the
|
||||
// not null when trick it makes the compiler think that requirement
|
||||
// could actually be nullable.
|
||||
throw new UnreachableException();
|
||||
}
|
||||
|
||||
if (authorized)
|
||||
|
@ -1,6 +1,8 @@
|
||||
using Bit.Api.Vault.Models.Response;
|
||||
using Bit.Core.Models.Api;
|
||||
|
||||
#nullable enable
|
||||
|
||||
public class OptionalCipherDetailsResponseModel : ResponseModel
|
||||
{
|
||||
public bool Unavailable { get; set; }
|
||||
|
Reference in New Issue
Block a user