Post by opentoshopping » Fri Apr 13, 2018 9:30 pm

HI,

I have opencart 2.3.0.2 with Journal theme, and everything used to work, untill suddenly I get a weird error when going to checkout. See below:

Code: Select all

Fatal error: Uncaught Error: Call to undefined method Cart\Currency::set() in /xx/system/storage/modification/catalog/controller/checkout/checkout.php:27 Stack trace: #0 /xx/system/storage/modification/system/engine/action.php(51): ControllerCheckoutCheckout->index() #1 /xx/catalog/controller/startup/router.php(25): Action->execute(Object(Registry)) #2 /xx/system/storage/modification/system/engine/action.php(51): ControllerStartupRouter->index() #3 /xx/system/engine/front.php(59): Action->execute(Object(Registry)) #4 /xx/system/engine/front.php(52): Front->execute(Object(Action)) #5 /xx/system/framework.php(223): Front->dispatch(Object(Action), Object(Action)) #6 /xx/system/startup.php(124): require_once('/home/ibow in /xx/system/storage/modification/catalog/controller/checkout/checkout.php on line 27
I've checked the modification/catalog/ checkout file at line 27 and see:

Code: Select all

$this->load->language('checkout/checkout');
	        $this->currency->set('EUR'); //Help fix this
It looks like the $this->currency->set('EUR') doesn't work. When I remove that line (by commenting it out) the site works again, and checkout works too.
Because it's in the modifications/catalog folder, it looks like it's a plugin or some extension causing the error.
Every time I refresh modifications, that line is added, and the site doesn't work again.

See below some error logs from modifications screen. I've attached full error log.

Who knows where to look? What can be causing this?

Code: Select all

2018-02-26 10:15:31 - MOD: Modification Default

FILE: system/engine/action.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 41

FILE: system/engine/loader.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 49
LINE: 108
LINE: 120
LINE: 165

FILE: system/library/config.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 23

FILE: system/library/language.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 38
LINE: 40
LINE: 49
LINE: 51
LINE: 60
LINE: 62

FILE: system/library/template/php.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 18

FILE: system/library/template/tiwg.php
REGEX: ~(require|include)(_once)?\(([^)]+)~
LINE: 24
----------------------------------------------------------------
MOD: Journal2
CODE: public function __construct($registry) {
LINE: 15

FILE: admin/controller/extension/extension/module.php
CODE: $this->load->controller('extension/module/' . $this->request->get['extension'] . '/install');
LINE: 33
CODE: $this->load->controller('extension/module/' . $this->request->get['extension'] . '/uninstall');
LINE: 59
----------------------------------------------------------------
MOD: X-Shipping Pro

FILE: catalog/view/theme/journal2/template/journal2/checkout/shipping_methods.tpl
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 24
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 19

FILE: catalog/view/theme/journal2/template/journal2/checkout/checkout.tpl
CODE: $(document).trigger('journal_checkout_reload_cart');
LINE: 437

FILE: catalog/view/theme/default/template/checkout/shipping_method.tpl
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 22
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 17

FILE: catalog/view/theme/journal2/template/checkout/shipping_method.tpl
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 23
CODE: <?php echo $quote['title']; ?> - <?php echo $quote['text']; ?>
LINE: 18

FILE: catalog/model/checkout/order.php
CODE: $data['shipping_method'] = $order_info['shipping_method'];
LINE: 451


Posts

Joined
Sun Mar 11, 2018 8:45 pm

Post by Johnathan » Fri Apr 13, 2018 10:04 pm

This is an error caused by an ocMod, so you'll need to figure out which one it is. If you can't tell by the ocMod log, I'd start by disabling all your ocMods, then start enabling a few at a time, until you figure out which one is causing it. Then you can contact the author of the mod and get them to take a look at it.

Don't forget to refresh your ocMod cache in Extensions > Modifications every time you enable/disable an ocMod.

Image
Image Image Image Image Image Image


User avatar
Global Moderator

Posts

Joined
Fri Dec 18, 2009 3:08 am

Who is online

Users browsing this forum: No registered users and 7 guests