public Artist FindById(string id) { Int32 realId; if (!Int32.TryParse(id, out realId)) { WebOperationContext.Current.OutgoingResponse.StatusCode = HttpStatusCode.NotFound; return(null); } else { return(artistDao.FindById(realId)); } }
//[Route("api/Artists/{id:int}")] public Artist Get(int id) { return(artistDao.FindById(id)); }