From d9e1f3abfa86dea4a16da2535682f1b4d56d7543 Mon Sep 17 00:00:00 2001 From: Cesar Velez Date: Thu, 2 Nov 2017 15:39:38 -0400 Subject: [PATCH] LP#1722899 - Fix bug due undefined pay note value Prevent error due to null or undefined pay_note.value Signed-off by: Cesar Velez --- Open-ILS/web/js/ui/default/staff/circ/patron/bills.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Open-ILS/web/js/ui/default/staff/circ/patron/bills.js b/Open-ILS/web/js/ui/default/staff/circ/patron/bills.js index daa5ae4fb7..1ead1cc74c 100644 --- a/Open-ILS/web/js/ui/default/staff/circ/patron/bills.js +++ b/Open-ILS/web/js/ui/default/staff/circ/patron/bills.js @@ -503,7 +503,8 @@ function($scope , $q , $routeParams , egCore , egConfirmDialog , $location, function() { // amount confirmed add_payment_note().then(function(pay_note) { add_cc_args().then(function(cc_args) { - sendPayment(pay_note.value, cc_args); + var note_text = pay_note ? pay_note.value || '' : null; + sendPayment(note_text, cc_args); }) }); }, -- 2.11.0