Пример #1
0
        public async Task <IActionResult> DeleteConfirmed(int id)
        {
            if (id <= 0)
            {
                return(NotFound());
            }

            try
            {
                await _filmsService.DeleteFilm(id);
            }
            catch
            {
                BadRequest();
            }
            return(RedirectToAction(nameof(Index)));
        }