astral-api/Astral.Services/Exceptions/InvalidCredentialsException.cs
2024-12-11 20:36:30 +00:00

26 lines
777 B
C#

// <copyright file="InvalidCredentialsException.cs" company="alveus.dev">
// Copyright (c) alveus.dev. All rights reserved. Licensed under the MIT License.
// </copyright>
using System.Net;
using Astral.Core.Exceptions;
using Astral.Services.Constants;
namespace Astral.Services.Exceptions;
/// <summary>
/// Thrown if username/password is incorrect.
/// </summary>
public class InvalidCredentialsException : ServiceException
{
/// <summary>
/// Initializes a new instance of the <see cref="InvalidCredentialsException" /> class.
/// </summary>
public InvalidCredentialsException()
: base(
ServiceErrorCodes.InvalidCredentials,
"The credentials provided were incorrect",
HttpStatusCode.Unauthorized)
{
}
}