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

[PM-22380] Enable NRT for some Core project files (#5912)

* Enable NRT for Core/Jobs files

* Enable NRT for Core/HostedServices files

* Enable NRT for Core/Exceptions files

* Enable NRT for Core/NotificationHub files

---------

Co-authored-by: Bernd Schoolmann <mail@quexten.com>
This commit is contained in:
Ben Bryant
2025-06-06 12:59:57 +01:00
committed by GitHub
parent 25d5efacd8
commit 20d3911b80
26 changed files with 99 additions and 39 deletions

View File

@@ -3,6 +3,8 @@ using Microsoft.AspNetCore.Mvc.ModelBinding;
namespace Bit.Core.Exceptions;
#nullable enable
public class BadRequestException : Exception
{
public BadRequestException() : base()
@@ -41,5 +43,5 @@ public class BadRequestException : Exception
}
}
public ModelStateDictionary ModelState { get; set; }
public ModelStateDictionary? ModelState { get; set; }
}

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class ConflictException : Exception
{
public ConflictException() : base("Conflict.") { }

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class DnsQueryException : Exception
{
public DnsQueryException(string message)

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class DomainClaimedException : Exception
{
public DomainClaimedException()

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class DomainVerifiedException : Exception
{
public DomainVerifiedException()

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class DuplicateDomainException : Exception
{
public DuplicateDomainException()

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
/// <summary>
/// Exception to throw when a requested feature is not yet enabled/available for the requesting context.
/// </summary>

View File

@@ -1,8 +1,10 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class GatewayException : Exception
{
public GatewayException(string message, Exception innerException = null)
public GatewayException(string message, Exception? innerException = null)
: base(message, innerException)
{ }
}

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class InvalidEmailException : Exception
{
public InvalidEmailException()

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class InvalidGatewayCustomerIdException : Exception
{
public InvalidGatewayCustomerIdException()

View File

@@ -1,5 +1,7 @@
namespace Bit.Core.Exceptions;
#nullable enable
public class NotFoundException : Exception
{
public NotFoundException() : base()