public async Task <IActionResult> Index() { var API = new YelpAPI.YelpHelpers(); var authenticated = await API.Authenticate(AppKeys, _context); if (authenticated) { } return(View()); }
public async Task <IActionResult> Search([Bind("Term, Location")] YelpSearch search) { var API = new YelpAPI.YelpHelpers(); var authenticated = await API.Authenticate(AppKeys, _context); if (authenticated) { YelpSearchResult searchResult = await API.GetResults(_context, search); return(View("YelpResult", searchResult)); } return(View()); }