예제 #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            notatweetRepository.Delete(id);
            notatweetRepository.Save();

            return(RedirectToAction("Index"));
        }
예제 #2
0
        // DELETE /api/notatwitterapi/5
        public void Delete(int id)
        {
            var notatweet = notatweetRepository.Find(id);

            if (notatweet == null)
            {
                throw new HttpResponseException(HttpStatusCode.NotFound);
            }

            notatweetRepository.Delete(id);
        }