public bool OptionExists(int id)
{
return _context.Option.Any(e => e.OptionID == id);
//var city = AggregateOptionExists.GetAggregateOption(id);
//if (city == null)
// {
// return NotFound();
// }
// return city;
}
I am having null values in Db how to handle null reference exception at _context.Option

Sachin SinghRank #66 · 26.2K reputationPosted May 28, 2021, 7:45 AM EDT
sankeerth mRank #3,390 · 425 reputationPosted May 28, 2021, 7:57 AM EDT