public ActionResult <List <Quotation> > AdminGetAll() { try { _logger.LogDebug("Admin fetching all quotations"); List <Quotation> quotes = _quotationService.AdminGetAll(); if (quotes != null) { _logger.LogDebug("Quotations fetch operation success."); return(Ok(quotes)); } else { _logger.LogDebug("Quotations fetch operation failed. No invoices found"); return(Conflict("No Invoices Found")); } } catch (Exception ex) { //Log error _logger.LogError("An Exception occured: {ex}", ex.Message); _logger.LogError("Stack Trace: {ex}", ex.StackTrace); return(BadRequest(ex)); } }