From fd4633d2a2f501ba822288b27d88a2b66d28ffd3 Mon Sep 17 00:00:00 2001 From: sairaj mote Date: Sun, 22 May 2022 18:18:46 +0530 Subject: [PATCH] added check if rejection reason is not specified --- scripts/fn_ui.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/fn_ui.js b/scripts/fn_ui.js index 5b6cf6f..f4718af 100644 --- a/scripts/fn_ui.js +++ b/scripts/fn_ui.js @@ -395,6 +395,8 @@ function declineTopUp() { if (reason === 'other') { reason = getRef('top_up__specified_reason').value } + if (reason.trim() === '') + return notify('Please specify a reason', 'error'); Cashier.rejectRequest(floGlobals.cashierProcessingRequest, reason).then(result => { console.log(result); console.info('Rejected cash-to-token request:', vectorClock);