public async Task <IActionResult> Get(string id) { if (string.IsNullOrEmpty(id) || id.Length != Requirements.PatientIdLength) { return(BadRequest()); } var patient_prescriptions = await _prescriptions.PatientPerscriptions(id); foreach (var presc in patient_prescriptions) { presc.MedicineName = (await _drugs.Get(presc.MedicineCode)).BrandName; } return(Ok(patient_prescriptions)); }