Misc code enhancements

This commit is contained in:
Łukasz Domeradzki
2024-04-04 02:15:16 +02:00
parent 990e696b37
commit 1841cde776
8 changed files with 32 additions and 29 deletions

View File

@@ -72,6 +72,6 @@ public sealed class IPCBansController : ArchiController {
/// Gets all IP addresses currently blocked by ASFs IPC module
/// </summary>
[HttpGet]
[ProducesResponseType<GenericResponse<ISet<string>>>((int) HttpStatusCode.OK)]
public ActionResult<GenericResponse<ISet<string>>> Get() => Ok(new GenericResponse<ISet<string>>(ApiAuthenticationMiddleware.GetCurrentlyBannedIPs().Select(static ip => ip.ToString()).ToHashSet()));
[ProducesResponseType<GenericResponse<IReadOnlySet<string>>>((int) HttpStatusCode.OK)]
public ActionResult<GenericResponse<IReadOnlySet<string>>> Get() => Ok(new GenericResponse<IReadOnlySet<string>>(ApiAuthenticationMiddleware.GetCurrentlyBannedIPs().Select(static ip => ip.ToString()).ToHashSet()));
}