custom async return object c#
try
            {
                var Collection = <query db context>
                if (Collection == null)
                {
                    return NotFound();
                }
                return Collection;
            }
            catch (Exception ex)
            {
               return new ObjectResult(ex);
            }