Switch to the new trigger pattern.
[platal.git] / modules / payment.php
index 8bc8285..9de57d1 100644 (file)
@@ -46,7 +46,7 @@ function paypal_erreur($text, $send=true)
     $mymail->setTxtBody("\n\n".var_export($_REQUEST,true));
     $mymail->send();
 
-    $page->trig($text);
+    $page->trigError($text);
 }
 
 /* http://fr.wikipedia.org/wiki/Formule_de_Luhn */
@@ -128,13 +128,13 @@ class PaymentModule extends PLModule
         $pay  = new Payment($ref);
 
         if($pay->flags->hasflag('old')){
-            $page->trig("La transaction selectionnée est périmée.");
+            $page->trigError("La transaction selectionnée est périmée.");
             $pay = new Payment();
         }
         $val = Env::v('montant') != 0 ? Env::v('montant') : $pay->montant_def;
 
         if (($e = $pay->check($val)) !== true) {
-            $page->trig($e);
+            $page->trigError($e);
         }
 
         if ($op=='submit') {