[Skip to main content](#vessel-content)

#   Error on checkout in PHP8

##

- **[Thrane](/forum/user/31786-thrane "View Thrane's Profile")**
- [![Thrane's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/31786-thrane "View Thrane's Profile") Topic Author
- [ Offline](/forum/user/31786-thrane)

Less More

- Posts: 366
- Thank you received: 26
-
-

4 years 10 months ago [\#338014](#338014) by [Thrane](/forum/user/31786-thrane "View Thrane's Profile")  *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338014 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")* was created by *[Thrane](/forum/user/31786-thrane "View Thrane's Profile")*

-- url of the page with the problem -- : [ tasteofport.dk/shop/kurv](https://tasteofport.dk/shop/kurv)
-- HikaShop version -- : 4.4.4
-- Joomla version -- : 3.10.4
-- PHP version -- : 8.0

Hi

Just tried switching to PHP8, but when I want to check out, I get an error:

current(): Argument #1 ($array) must be of type array, null given

Any advice?

Regards
Thomas

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86363
- Thank you received: 14296
-
-

4 years 10 months ago [\#338016](#338016) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338016 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Hi,

First, activate the "debug system" setting of the Joomla configuration. Then, reproduce the error. It will give more information which will help us understand what's going on so that we can tell you what to do.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Thrane](/forum/user/31786-thrane "View Thrane's Profile")**
- [![Thrane's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/31786-thrane "View Thrane's Profile") Topic Author
- [ Offline](/forum/user/31786-thrane)

Less More

- Posts: 366
- Thank you received: 26
-
-

4 years 10 months ago [\#338047](#338047) by [Thrane](/forum/user/31786-thrane "View Thrane's Profile")  Replied by *[Thrane](/forum/user/31786-thrane "View Thrane's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338047 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Thanks, I have set it to Development, but I don't see more info?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86363
- Thank you received: 14296
-
-

4 years 10 months ago [\#338051](#338051) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338051 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Hi,

The the "debug system" setting is a "yes/no" choice, not a dropdown. You must not be looking at the correct setting.
Please check again.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Thrane](/forum/user/31786-thrane "View Thrane's Profile")**
- [![Thrane's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/31786-thrane "View Thrane's Profile") Topic Author
- [ Offline](/forum/user/31786-thrane)

Less More

- Posts: 366
- Thank you received: 26
-
-

4 years 10 months ago [\#338057](#338057) by [Thrane](/forum/user/31786-thrane "View Thrane's Profile")  Replied by *[Thrane](/forum/user/31786-thrane "View Thrane's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338057 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Sorry, got it mixed up with Error Reporting ...

Now I see this:

current(): Argument #1 ($array) must be of type array, null given
/var/www/vhosts/tasteofport.dk/httpdocs/plugins/hikashop/awocoupon/awocoupon.php:208
Call stack
\# Function Location
1 () JROOT/plugins/hikashop/awocoupon/awocoupon.php:208
2 current() JROOT/plugins/hikashop/awocoupon/awocoupon.php:208
3 plgHikashopAwoCoupon-&gt;onHikashopAfterDisplayView() JROOT/libraries/joomla/event/event.php:70
4 JEvent-&gt;update() JROOT/libraries/joomla/event/dispatcher.php:160
5 JEventDispatcher-&gt;trigger() JROOT/libraries/src/Application/BaseApplication.php:108
6 Joomla\CMS\Application\BaseApplication-&gt;triggerEvent() JROOT/administrator/components/com_hikashop/helpers/helper.php:2608
7 hikashopView-&gt;display() JROOT/components/com_hikashop/views/checkout/view.html.php:53
8 CheckoutViewCheckout-&gt;display() JROOT/libraries/src/MVC/Controller/BaseController.php:664
9 Joomla\CMS\MVC\Controller\BaseController-&gt;display() JROOT/administrator/components/com_hikashop/helpers/helper.php:2308
10 hikashopController-&gt;display() JROOT/components/com_hikashop/controllers/checkout.php:65
11 checkoutController-&gt;display() JROOT/components/com_hikashop/controllers/checkout.php:213
12 checkoutController-&gt;show() JROOT/libraries/src/MVC/Controller/BaseController.php:702
13 Joomla\CMS\MVC\Controller\BaseController-&gt;execute() JROOT/administrator/components/com_hikashop/helpers/helper.php:2286
14 hikashopController-&gt;execute() JROOT/components/com_hikashop/hikashop.php:88
15 require_once() JROOT/libraries/src/Component/ComponentHelper.php:402
16 Joomla\CMS\Component\ComponentHelper::executeComponent() JROOT/libraries/src/Component/ComponentHelper.php:377
17 Joomla\CMS\Component\ComponentHelper::renderComponent() JROOT/libraries/src/Application/SiteApplication.php:194
18 Joomla\CMS\Application\SiteApplication-&gt;dispatch() JROOT/libraries/src/Application/SiteApplication.php:233
19 Joomla\CMS\Application\SiteApplication-&gt;doExecute() JROOT/libraries/src/Application/CMSApplication.php:225
20 Joomla\CMS\Application\CMSApplication-&gt;execute() JROOT/index.php:49

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86363
- Thank you received: 14296
-
-

4 years 10 months ago [\#338060](#338060) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338060 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Hi,

The error comes from an AWOCoupon plugin.
So you need to contact the developer of AWOCoupon to report that error to them. They'll be able to fix it and give you a solution.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Thrane](/forum/user/31786-thrane "View Thrane's Profile")**
- [![Thrane's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/31786-thrane "View Thrane's Profile") Topic Author
- [ Offline](/forum/user/31786-thrane)

Less More

- Posts: 366
- Thank you received: 26
-
-

4 years 10 months ago [\#338070](#338070) by [Thrane](/forum/user/31786-thrane "View Thrane's Profile")  Replied by *[Thrane](/forum/user/31786-thrane "View Thrane's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338070 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

Thank you, will do that right away! ![:-)](/media/kunena/emoticons/3.png ":-)")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Thrane](/forum/user/31786-thrane "View Thrane's Profile")**
- [![Thrane's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/31786-thrane "View Thrane's Profile") Topic Author
- [ Offline](/forum/user/31786-thrane)

Less More

- Posts: 366
- Thank you received: 26
-
-

4 years 10 months ago [\#338078](#338078) by [Thrane](/forum/user/31786-thrane "View Thrane's Profile")  Replied by *[Thrane](/forum/user/31786-thrane "View Thrane's Profile")* on topic *[Error on checkout in PHP8](/forum/27-checkout/903678-error-on-checkout-in-php8#338078 "-- url of the page with the problem -- :   tasteofport.dk/shop/kurv  -- HikaShop version -- : 4.4.4 -- Joomla version -- : 3.10.4 -- PHP version -- : 8.0  Hi  Just tried switching to PHP8, but when I want to check out, I get an error:  current(): Argument #1 ($array) must be of type array, null given  Any advice?  Regards Thomas")*

If others get this error, this is the fix from AwoCoupon:

In /plugins/hikashop/awocoupon/awocoupon.php at line 204 is this: Code:

&lt;?php $coupon_session = AC()-&gt;storediscount-&gt;get_coupon_session(); ?&gt;

Right after that add this Code:

&lt;?php if ( empty( $coupon_session ) ) { return; } ?&gt;

The following user(s) said Thank You: [nicolas](/forum/user/63-nicolas "View nicolas's Profile"), [aftertaf](/forum/user/13416-aftertaf "View aftertaf's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwMzY3OC1lcnJvci1vbi1jaGVja291dC1pbi1waHA4P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.061 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
