Skip to content

Commit

Permalink
EPCT-5 Not working drug refill action (#702)
Browse files Browse the repository at this point in the history
* Fix active prescription validation for non arv items
  • Loading branch information
ynurmahomed authored and Guimino committed Jul 25, 2018
1 parent 524d41e commit be86574
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/common/prescription/components/prescription.js
Expand Up @@ -330,7 +330,7 @@
}

function validateCreatePrescription(prescription) {
if (prescription.regime.isArv && hasActiveArvPrescription()) {
if (prescription.regime && prescription.regime.isArv && hasActiveArvPrescription()) {
notifier.error($filter('translate')('COMMON_MESSAGE_COULD_NOT_CREATE_ARV_PRESCRIPTION_BECAUSE_EXISTS_AN_ACTIVE_ARV_PRESCRIPTION'));
return false;
}
Expand Down

0 comments on commit be86574

Please sign in to comment.