You are here

function uc_credit_exit in Ubercart 5

Same name and namespace in other branches
  1. 6.2 payment/uc_credit/uc_credit.module \uc_credit_exit()
  2. 7.3 payment/uc_credit/uc_credit.module \uc_credit_exit()

Implementation of hook_exit().

File

payment/uc_credit/uc_credit.module, line 242
Defines the credit card payment method and hooks in payment gateways.

Code

function uc_credit_exit() {

  // Separate the args ourself since the arg() function may not be loaded.
  $args = explode('/', $_GET['q']);

  // Make sure sensitive checkout session data doesn't persist on other pages.
  if (isset($_SESSION['sescrd']) && (!isset($args[1]) || $args[0] != 'cart' || $args[1] != 'checkout')) {
    unset($_SESSION['sescrd']);
  }
}