Jump to content

Hook::exec Question


mastershay1

Recommended Posts

Front Office

Order Checkout page

 

I added custom UPS code to my site. When I select a carrier or update the product quantities, a 500 Interal error is returned by ajax.

 

I narrowed the error down to the line below.

 

 

File:

classes/controller/Controller.php

//This line works
Hook::exec('actionBeforeAjaxDie', array('controller' => $controller, 'method' => $method, 'value' => $value));

//Very next line causes the ajax error

Hook::exec('actionBeforeAjaxDie'.$controller.$method, array('value' => $value));

 

 

 

It tries to use "actionBeforeAjaxDieOrderOpcControllerControllerCore::ajaxDie" as the value. Why is Hook::exec called twice in row and why is the second one attempting to send that?

 

I removed the second line and it appears to work correctly, but I don't know how this affects the rest of the site.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...