Forums / Bug Reports / [Done v1.5.0] PayPal ipnhandler might insert extra order status history notice

[Done v1.5.0] PayPal ipnhandler might insert extra order status history notice

Locked

Views: 832

Results 1 to 1 of 1
This thread is locked. New replies are disabled.
23 Jul 2011, 4:22 PM
#1
nlinksolution avatar

nlinksolution

New Zenner

Join Date:
Sep 2010
Posts:
32
Plugin Contributions:
0

[Done v1.5.0] PayPal ipnhandler might insert extra order status history notice

I am talking about latest zencart 1.3.9h and the script is

root > ipn_main_handler.php

Around line 347

There is a code like this

zen_db_perform(TABLE_ORDERS_STATUS_HISTORY, $sql_data_array);
        if (MODULE_PAYMENT_PAYPAL_ADDRESS_OVERRIDE == '1') {
          $sql_data_array['comments'] = '**** ADDRESS OVERRIDE ALERT!!! **** CHECK PAYPAL ORDER DETAILS FOR ACTUAL ADDRESS SELECTED BY CUSTOMER!!';
          $sql_data_array['customer_notified'] = -1;
        }
        zen_db_perform(TABLE_ORDERS_STATUS_HISTORY, $sql_data_array)

But this should be changed to this

zen_db_perform(TABLE_ORDERS_STATUS_HISTORY, $sql_data_array);
        if (MODULE_PAYMENT_PAYPAL_ADDRESS_OVERRIDE == '1') {
          $sql_data_array['comments'] = '**** ADDRESS OVERRIDE ALERT!!! **** CHECK PAYPAL ORDER DETAILS FOR ACTUAL ADDRESS SELECTED BY CUSTOMER!!';
          $sql_data_array['customer_notified'] = -1;
          zen_db_perform(TABLE_ORDERS_STATUS_HISTORY, $sql_data_array);
        }

ISSUE in code is if MODULE_PAYMENT_PAYPAL_ADDRESS_OVERRIDE = 0 then it add a record twice in order status history.

And in result it appears twice in order page admin panel. As attached