- Posts: 75
- Thank you received: 7
Call to a member function getCart() on null when editing user information
- wildweststudios
-
Topic Author
- Offline
Less
More
6 years 10 months ago #312881
by wildweststudios
Call to a member function getCart() on null when editing user information was created by wildweststudios
-- HikaShop version -- : 4.2.2
-- Joomla version -- : 3.9.13
-- PHP version -- : 7.2.24
-- Browser(s) name and version -- : Google Chrome Version 78.0.3904.87 (Official Build) (64-bit)
-- Error-message(debug-mod must be tuned on) -- : Call to a member function getCart() on null
/mnt/data/vhosts/casite-584904.cloudaccess.net/httpdocs/administrator/components/com_hikashop/classes/address.php:246
Call stack
# Function Location
1 () JROOT/administrator/components/com_hikashop/classes/address.php:246
2 hikashopAddressClass->save() JROOT/administrator/components/com_hikashop/controllers/user.php:118
3 UserController->saveaddress() JROOT/libraries/src/MVC/Controller/BaseController.php:710
4 Joomla\CMS\MVC\Controller\BaseController->execute() JROOT/administrator/components/com_hikashop/helpers/helper.php:1976
5 hikashopController->execute() JROOT/administrator/components/com_hikashop/hikashop.php:72
6 require_once() JROOT/libraries/src/Component/ComponentHelper.php:402
7 Joomla\CMS\Component\ComponentHelper::executeComponent() JROOT/libraries/src/Component/ComponentHelper.php:377
8 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/AdministratorApplication.php:101
9 Joomla\CMS\Application\AdministratorApplication->dispatch() JROOT/libraries/src/Application/AdministratorApplication.php:159
10 Joomla\CMS\Application\AdministratorApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:196
11 Joomla\CMS\Application\CMSApplication->execute() JROOT/administrator/index.php:51
I haven't had to actually edit the customer information for awhile, so I'm not sure if this issue existed before I upgraded to the latest Hikashop version.
The 'Call to a member function getCart() on null' error appears when I click the OK button after editing the billing or shipping addresses after they are created.
I can create the billing/shipping address with no problems, but I cannot edit an existing one.
I set error reporting to maximum, and I pasted in the info that shows when I try to save an edit.
Thanks for any help.
-- Joomla version -- : 3.9.13
-- PHP version -- : 7.2.24
-- Browser(s) name and version -- : Google Chrome Version 78.0.3904.87 (Official Build) (64-bit)
-- Error-message(debug-mod must be tuned on) -- : Call to a member function getCart() on null
/mnt/data/vhosts/casite-584904.cloudaccess.net/httpdocs/administrator/components/com_hikashop/classes/address.php:246
Call stack
# Function Location
1 () JROOT/administrator/components/com_hikashop/classes/address.php:246
2 hikashopAddressClass->save() JROOT/administrator/components/com_hikashop/controllers/user.php:118
3 UserController->saveaddress() JROOT/libraries/src/MVC/Controller/BaseController.php:710
4 Joomla\CMS\MVC\Controller\BaseController->execute() JROOT/administrator/components/com_hikashop/helpers/helper.php:1976
5 hikashopController->execute() JROOT/administrator/components/com_hikashop/hikashop.php:72
6 require_once() JROOT/libraries/src/Component/ComponentHelper.php:402
7 Joomla\CMS\Component\ComponentHelper::executeComponent() JROOT/libraries/src/Component/ComponentHelper.php:377
8 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/AdministratorApplication.php:101
9 Joomla\CMS\Application\AdministratorApplication->dispatch() JROOT/libraries/src/Application/AdministratorApplication.php:159
10 Joomla\CMS\Application\AdministratorApplication->doExecute() JROOT/libraries/src/Application/CMSApplication.php:196
11 Joomla\CMS\Application\CMSApplication->execute() JROOT/administrator/index.php:51
I haven't had to actually edit the customer information for awhile, so I'm not sure if this issue existed before I upgraded to the latest Hikashop version.
The 'Call to a member function getCart() on null' error appears when I click the OK button after editing the billing or shipping addresses after they are created.
I can create the billing/shipping address with no problems, but I cannot edit an existing one.
I set error reporting to maximum, and I pasted in the info that shows when I try to save an edit.
Thanks for any help.
Please Log in or Create an account to join the conversation.
6 years 10 months ago #312894
by nicolas
Replied by nicolas on topic Call to a member function getCart() on null when editing user information
Hi,
Thank you for the details.
You can change the line:
$checkoutHelper = hikashop_get('class.checkout');
To:
$checkoutHelper = hikashop_get('helper.checkout');
in the file /administrator/components/com_hikashop/classes/address.php and that will fix the problem.
We've added that patch on our end too so you can also download again the install package of HikaShop on our website and install it on yours to get the patch.
Thank you for the details.
You can change the line:
$checkoutHelper = hikashop_get('class.checkout');
To:
$checkoutHelper = hikashop_get('helper.checkout');
in the file /administrator/components/com_hikashop/classes/address.php and that will fix the problem.
We've added that patch on our end too so you can also download again the install package of HikaShop on our website and install it on yours to get the patch.
Please Log in or Create an account to join the conversation.
- wildweststudios
-
Topic Author
- Offline
Less
More
- Posts: 75
- Thank you received: 7
6 years 10 months ago #312909
by wildweststudios
Replied by wildweststudios on topic Call to a member function getCart() on null when editing user information
Yes that worked perfectly, thanks!
Please Log in or Create an account to join the conversation.
6 years 7 months ago #315772
by sauvain
Replied by sauvain on topic Call to a member function getCart() on null when editing user information
I have the same problem as described in this ticket.
I changed the line as described:
$checkoutHelper = hikashop_get('class.checkout');
To:
$checkoutHelper = hikashop_get('helper.checkout');
There is no error anymore but the modification is not applied.
I changed the line as described:
$checkoutHelper = hikashop_get('class.checkout');
To:
$checkoutHelper = hikashop_get('helper.checkout');
There is no error anymore but the modification is not applied.
Please Log in or Create an account to join the conversation.
6 years 7 months ago #315777
by nicolas
Replied by nicolas on topic Call to a member function getCart() on null when editing user information
Hi,
First, please download the install package of the 4.2.2 on our website and install it on yours. That way, you'll get all the latest patches.
Then please try to reproduce the issue, and if you do, please provide a link with precise instructions for us to be able to reproduce the issue.
First, please download the install package of the 4.2.2 on our website and install it on yours. That way, you'll get all the latest patches.
Then please try to reproduce the issue, and if you do, please provide a link with precise instructions for us to be able to reproduce the issue.
Please Log in or Create an account to join the conversation.
Time to create page: 0.180 seconds