From 9d01e07db9691d3d443851a3a7c9b5e79be4fd5a Mon Sep 17 00:00:00 2001 From: Jean Date: Sat, 24 Sep 2022 12:43:24 +0200 Subject: [PATCH] FIX #22386 IBAN not mandatory for International Export Countries --- htdocs/societe/paymentmodes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/societe/paymentmodes.php b/htdocs/societe/paymentmodes.php index 873795c938e..b3f3ad95a1a 100644 --- a/htdocs/societe/paymentmodes.php +++ b/htdocs/societe/paymentmodes.php @@ -125,6 +125,7 @@ if (empty($reshook)) { $action = 'edit'; $error++; } + $companybankaccount->fetch($id); if ($companybankaccount->needIBAN() == 1) { if (!GETPOST('iban')) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("IBAN")), null, 'errors'); @@ -138,7 +139,6 @@ if (empty($reshook)) { } } - $companybankaccount->fetch($id); if (!$error) { $companybankaccount->socid = $object->id;