You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
add
declare(strict_types=1);
to the start of functions_products
Add a product to the cart
PHP Fatal error: Uncaught TypeError: zen_get_prid(): Argument #1 ($uprid) must be of type string, int given, called in includes\functions\functions_products.php on line 550 and defined in \includes\functions\functions_products.php:458
I suggest adding the same (declare(strict_types=1);) to the shopping_cart class at the same time for related useages/as it is debateable exactly where fixes should be applied.
The text was updated successfully, but these errors were encountered:
drbyte
changed the title
functions_products: fatal error with shopping_cart when declare(strict_types=1);
functions_products: zen_get_prid(): Argument #1 ($uprid) must be of type string, int given
Jan 3, 2024
* Declare parameter as `string|int` for zen_get_prid
Fixes#6082
* Manually coerce values back and forth for strict-type limitations
* Force types
* Specify types
* Rework inspection for gift certs in cart
* Try to avoid loss of precision while implementing strict type support
* force override of coercive types to strict
add
declare(strict_types=1);
to the start of functions_products
Add a product to the cart
PHP Fatal error: Uncaught TypeError: zen_get_prid(): Argument #1 ($uprid) must be of type string, int given, called in includes\functions\functions_products.php on line 550 and defined in \includes\functions\functions_products.php:458
I suggest adding the same (declare(strict_types=1);) to the shopping_cart class at the same time for related useages/as it is debateable exactly where fixes should be applied.
The text was updated successfully, but these errors were encountered: