From c008cd2fcf4966d62f283e9b16150e1075804299 Mon Sep 17 00:00:00 2001 From: ethem Date: Tue, 3 Oct 2006 18:21:14 +0000 Subject: [PATCH] If an error occures, id returns 0. The user, who will be sent email, may be confused for $record->id=0. Merged from 16stable. --- enrol/authorize/authorizenetlib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/enrol/authorize/authorizenetlib.php b/enrol/authorize/authorizenetlib.php index a1b4c5f2e3..d3b83ab597 100644 --- a/enrol/authorize/authorizenetlib.php +++ b/enrol/authorize/authorizenetlib.php @@ -331,7 +331,7 @@ function authorize_action(&$order, &$message, &$extra, $action=AN_ACTION_NONE, $ $extra->transid = $transid; $extra->settletime = authorize_getsettletime(time()); unset($extra->sum); // this is not used in refunds table. - if (! $extra->id = insert_record('enrol_authorize_refunds', $extra)) { + if (! insert_record('enrol_authorize_refunds', $extra)) { email_to_admin("Error while trying to insert data " . "into table enrol_authorize_refunds. Please add manually this record:", $extra); } -- 2.39.5