diff --git a/htdocs/societe/rib.php b/htdocs/societe/rib.php
index 0017a7486cfba9c39237e1032277d08c5fa562fc..8218838ab67859439af47039195e1b1ae979d748 100644
--- a/htdocs/societe/rib.php
+++ b/htdocs/societe/rib.php
@@ -95,7 +95,7 @@ $head=societe_prepare_head2($soc);
 dol_fiche_head($head, 'rib', $langs->trans("ThirdParty"),0,'company');
 
 $account = new CompanyBankAccount($db);
-$account->fetch(0,$soc->id);
+$account->socid=$soc->id;