-
iCagenda
-
iCagenda - English
-
[FIX 3.8.15] error: array_merge(): Argument #2 must be of type array, bool given
[FIX 3.8.15] error: array_merge(): Argument #2 must be of type array, bool given
-
Joomilette
-
Auteur du sujet
-
Nouveau membre
-
Réduire
Plus d'informations
-
Messages : 8
-
Remerciements reçus 4
-
-
il y a 1 an 9 mois - il y a 1 an 9 mois #18092
par Joomilette
Hi,
my configuration: Joomla 4.2.28, PHP 8.1, iCagenda 3.8.14
since yesterdays update from iCagenda 3.8.13 to 3.8.14 I am getting a critical error :Uncaught Throwable of type TypeError thrown with message "array_merge():
Argument #2 must be of type array, bool given".
Stack trace: #0 [ROOT]\components\com_icagenda\src\Model\RegistrationModel.php(1521): array_merge()
Obviously something went wrong with this array_merge()
My workaround goes like this:
I commented this line out
// $customfields = $customfields ? array_merge($customfields, $eventCustomfields) : $eventCustomfields;
and replaced it with
$customfields = $eventCustomfields;
No idea whether this works for other users, but for me it was fine. As I do not have any other customfields but only one single eventCustomfield.
Hope you guys can fix this issue in the next version.
Rgds Joomilette
Dernière édition: il y a 1 an 9 mois par Lyr!C.
Connexion ou Créer un compte pour participer à la conversation.
-
Lyr!C
-
-
Administrateur
-
-
Lead Developer
Réduire
Plus d'informations
-
Messages : 6780
-
Remerciements reçus 608
-
-
-
-
il y a 1 an 9 mois #18093
par Lyr!C
Hello,
Well, i did miss a control for PHP8...
But your workaround is not good... (and won't work if custom fields).
Replace the line by this :
$customfields = is_array($customfields) ? array_merge($customfields, $eventCustomfields) : $eventCustomfields;
I think it will solve the issue.
Could you test it ?
I will check it tomorrow, and release a new update to fix it.
Thanks for report!
Best regards,
Cyril
Latest version : iCagenda 3.9.7
We recommend every user to keep iCagenda updated.
Don't forget to have your Joomla!™ up-to-date!
Do you like iCagenda?
I would appreciate if you could take 5 minutes to post a review on
JED (Joomla Extensions Directory)
.
Connexion ou Créer un compte pour participer à la conversation.
-
Lyr!C
-
-
Administrateur
-
-
Lead Developer
Réduire
Plus d'informations
-
Messages : 6780
-
Remerciements reçus 608
-
-
-
-
il y a 1 an 9 mois #18095
par Lyr!C
Edit : in fact, not the correct fix...
What is strange, is that i'm not able to duplicate this issue...
Cyril
Latest version : iCagenda 3.9.7
We recommend every user to keep iCagenda updated.
Don't forget to have your Joomla!™ up-to-date!
Do you like iCagenda?
I would appreciate if you could take 5 minutes to post a review on
JED (Joomla Extensions Directory)
.
Connexion ou Créer un compte pour participer à la conversation.
-
Lyr!C
-
-
Administrateur
-
-
Lead Developer
Réduire
Plus d'informations
-
Messages : 6780
-
Remerciements reçus 608
-
-
-
-
il y a 1 an 9 mois #18096
par Lyr!C
Could you test to replace this:
$customfields = $customfields ? array_merge($customfields, $eventCustomfields) : $eventCustomfields;
By this:
$eventCustomfields = $eventCustomfields ?: [];
$customfields = $customfields ? array_merge($customfields, $eventCustomfields) : $eventCustomfields;
And confirm that your issue is fixed ?
Thank you!
Regards,
Cyril
Latest version : iCagenda 3.9.7
We recommend every user to keep iCagenda updated.
Don't forget to have your Joomla!™ up-to-date!
Do you like iCagenda?
I would appreciate if you could take 5 minutes to post a review on
JED (Joomla Extensions Directory)
.
Les utilisateur(s) suivant ont remercié: Joomilette
Connexion ou Créer un compte pour participer à la conversation.
-
Joomilette
-
Auteur du sujet
-
Nouveau membre
-
Réduire
Plus d'informations
-
Messages : 8
-
Remerciements reçus 4
-
-
il y a 1 an 9 mois #18097
par Joomilette
Hi Cyril
you made my day! I just tested ist and now it is fixed!
Merci and bon soir!
Joomilette
Connexion ou Créer un compte pour participer à la conversation.
-
Lyr!C
-
-
Administrateur
-
-
Lead Developer
Réduire
Plus d'informations
-
Messages : 6780
-
Remerciements reçus 608
-
-
-
-
il y a 1 an 9 mois #18098
par Lyr!C
Hi Cyril
you made my day! I just tested ist and now it is fixed!
Merci and bon soir!
Joomilette
Hello,
And thank you for confirming this fix the issue for you!
I'm still not able to reproduce the bug... on same Joomla 4.2.8 and PHP 8.1.16...
You told me you had only one custom field for event parent form, that's right ?
How is set this custom field ? (text, list, radio buttons...)
And is data is stored for this event and custom field ?
I'm still trying to understand why this issue.
Thank you!
Best regards,
Cyril
Latest version : iCagenda 3.9.7
We recommend every user to keep iCagenda updated.
Don't forget to have your Joomla!™ up-to-date!
Do you like iCagenda?
I would appreciate if you could take 5 minutes to post a review on
JED (Joomla Extensions Directory)
.
Connexion ou Créer un compte pour participer à la conversation.
-
Joomilette
-
Auteur du sujet
-
Nouveau membre
-
Réduire
Plus d'informations
-
Messages : 8
-
Remerciements reçus 4
-
-
il y a 1 an 9 mois #18106
par Joomilette
Hello Cyril,
I created this field within component iCagenda „Additionals -> custom fields“.
Field Type is "Radio Buttons" with 2 options.
Furthermore this field is assigned to a group.
In the event itself I selected this group under „Registrations“ – „Registration Options“ - „Form Groups (Optional)“.
The data is stored for this event and custom field. E-Mail confirmation includes data and custom field as well.
The critical error came up right after submitting the registration form without sending any E-Mail confirmation but I could see the registration itself in the backend. As the session was still open a further „new“ registration attempt for the same event was overwriting the registration data of the first attempt in the backend.
After that I had a look in the log-file and found the error message.
Hope this information helps for reproducing the phenomen...
Regards
Joomilette
Les utilisateur(s) suivant ont remercié: Lyr!C
Connexion ou Créer un compte pour participer à la conversation.
-
Lyr!C
-
-
Administrateur
-
-
Lead Developer
Réduire
Plus d'informations
-
Messages : 6780
-
Remerciements reçus 608
-
-
-
-
il y a 1 an 9 mois #18108
par Lyr!C
Thank you for the information, it will be useful.
I still can't reproduce it... but i would like to understand why this has happened (even if the patch of version 3.8.15 fix it by adding an extra checking, still a mystery why some have it, but not everyone...)
Best regards,
Cyril
Latest version : iCagenda 3.9.7
We recommend every user to keep iCagenda updated.
Don't forget to have your Joomla!™ up-to-date!
Do you like iCagenda?
I would appreciate if you could take 5 minutes to post a review on
JED (Joomla Extensions Directory)
.
Connexion ou Créer un compte pour participer à la conversation.
-
iCagenda
-
iCagenda - English
-
[FIX 3.8.15] error: array_merge(): Argument #2 must be of type array, bool given
Temps de génération de la page : 0.115 secondes