public async Task<ActionResult> ManageNewsFeeds(string userID, IEnumerable<int> selectedIDs)
        {
            using (ApplicationDbContext context = new ApplicationDbContext())
            {                 
                ICollection<NewsFeed> newsFeeds = new List<NewsFeed>();
                ApplicationUser user = context.Users.Where(u => u.Id == userID).SingleOrDefault();
                user.NewsFeeds.Clear();

                if (selectedIDs != null)
                {
                    foreach (int newsFeedId in selectedIDs)
                    {                        
                        var daNewsFeeds = await context.NewsFeed.ToListAsync();

                        var daNewsFeed = daNewsFeeds.Where(n => n.NewsFeedID == newsFeedId).SingleOrDefault();

                        newsFeeds.Add(daNewsFeed);
                    }
                }                

                user.NewsFeeds = newsFeeds;
                await context.SaveChangesAsync();

                ManageNewsFeedsViewModel model = new ManageNewsFeedsViewModel();

                model.UserID = user.Id;
                model.NewsFeeds = user.NewsFeeds;

                return View(model);
            }        
        }
        public async Task<ActionResult> ManageNewsFeeds()
        {
            ManageNewsFeedsViewModel model = new ManageNewsFeedsViewModel();
            
            model.UserID = User.Identity.GetUserId();

            var user = await UserManager.FindByIdAsync(model.UserID);
            
            model.NewsFeeds = user.NewsFeeds.ToList();       
                 
            model.SelectedIDs.Clear();

            foreach (NewsFeed newsFeed in user.NewsFeeds)
            {
                model.SelectedIDs.Add(newsFeed.NewsFeedID);
            }
            
            return View(model);
        }