public IActionResult GetEvent(int eventID) { EventRepo eventRP = new EventRepo(_context); var query = eventRP.GetEvent(eventID); var resultObj = new { EventArray = query, }; return(new ObjectResult(resultObj)); }