This commit is contained in:
2021-10-18 19:09:06 +00:00
parent 0be9cf1f6b
commit 509c4e1336
6 changed files with 20 additions and 23 deletions

View File

@@ -1,4 +1,3 @@
using System.Collections.Generic;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
@@ -11,11 +10,6 @@ using Microsoft.Extensions.Logging;
using AyaNova.Models;
using AyaNova.Api.ControllerHelpers;
using AyaNova.Biz;
using System;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using Newtonsoft.Json.Linq;
using System.Linq;
using AyaNova.Util;
using System.IO;
@@ -65,8 +59,9 @@ namespace AyaNova.Api.Controllers
[HttpGet("{size}")]
public async Task<IActionResult> DownloadLogo([FromRoute] string size)
{
if (serverState.IsClosed)
return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
//allowing this because it messes up the login form needlessly
// if (serverState.IsClosed)
// return StatusCode(503, new ApiErrorResponse(serverState.ApiErrorCode, null, serverState.Reason));
if (!ModelState.IsValid)
return BadRequest(new ApiErrorResponse(ModelState));