public async Task <IActionResult> GetLaptopById(string id) { try { var laptop = await laptopService.GetById(id); return(laptop != null?Ok(laptop) : NotFound()); } catch (Exception ex) { return(BadRequest(ex.Message)); } }