public virtual IHttpActionResult GetEntity(int id) { TEntity entity = service.FindById(id); if (entity == null) { return(NotFound()); } return(Ok(entity)); }
public async virtual Task <IHttpActionResult> GetEntity(int id) { TEntity entity = await service.FindById(id); return(Ok(entity)); }