public IActionResult Delete(int id) { if (_deviceData.GetById(id) == null) { return(NotFound()); } _deviceData.Delete(id); return(Ok()); }