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

#   User creation via Joomla CLI

##

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

Less More

- Posts: 11
- Thank you received: 0
-
-

2 years 3 weeks ago [\#364250](#364250) by [Rivalland](/forum/user/58929-rivalland "View Rivalland's Profile")  *[User creation via Joomla CLI](/forum/25-install-update/908830-user-creation-via-joomla-cli#364250 "-- HikaShop version -- : 5.1.1 -- Joomla version -- : 5.2.0 -- PHP version -- : 8.2  We have a user account creation process via the new Joomla commands (php cli/joomla.php user:add ...) However, the &#96;hikashop&#95;user&#96; plugin system triggers an error on the &#96;onAfterStoreUser&#96; event.  There seems to be a use of not accessible from the Joomla CLI context. For the moment, we have been able to get around the problem by adding the following lines to &#96;hikashop&#95;user&#96;:")* was created by *[Rivalland](/forum/user/58929-rivalland "View Rivalland's Profile")*

-- HikaShop version -- : 5.1.1
-- Joomla version -- : 5.2.0
-- PHP version -- : 8.2

We have a user account creation process via the new Joomla commands (php cli/joomla.php user:add ...)
However, the &#96;hikashop_user&#96; plugin system triggers an error on the &#96;onAfterStoreUser&#96; event.

There seems to be a use of Code:

setUserState

not accessible from the Joomla CLI context.
For the moment, we have been able to get around the problem by adding the following lines to &#96;hikashop_user&#96;:

> if (method\_exists($app, ‘isClient’) &amp;&amp; $app-&gt;isClient(‘cli’)) {
> return;
> }

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI1LWluc3RhbGwtdXBkYXRlLzkwODgzMC11c2VyLWNyZWF0aW9uLXZpYS1qb29tbGEtY2xpP3RtcGw9bWFya2Rvd24=) 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")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86587
- Thank you received: 14326
-
-

2 years 3 weeks ago [\#364255](#364255) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[User creation via Joomla CLI](/forum/25-install-update/908830-user-creation-via-joomla-cli#364255 "-- HikaShop version -- : 5.1.1 -- Joomla version -- : 5.2.0 -- PHP version -- : 8.2  We have a user account creation process via the new Joomla commands (php cli/joomla.php user:add ...) However, the &#96;hikashop&#95;user&#96; plugin system triggers an error on the &#96;onAfterStoreUser&#96; event.  There seems to be a use of not accessible from the Joomla CLI context. For the moment, we have been able to get around the problem by adding the following lines to &#96;hikashop&#95;user&#96;:")*

Hi,

Thanks for your feedback. We'll be adding some patches for this for the next version of HikaShop.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI1LWluc3RhbGwtdXBkYXRlLzkwODgzMC11c2VyLWNyZWF0aW9uLXZpYS1qb29tbGEtY2xpP3RtcGw9bWFya2Rvd24=) 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.041 seconds

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