예제 #1
0
        public async Task <Comment> UpdateAsync(Comment comment)
        {
            _context.Entry(comment).State = EntityState.Modified;
            await _context.SaveChangesAsync();

            return(comment);
        }
예제 #2
0
        public async Task <Photo> UpdateAsync(Photo photo)
        {
            _context.Entry(photo).State = EntityState.Modified;
            await _context.SaveChangesAsync();

            return(photo);
        }