Plugin Contributor
Savvas
(@savvasha)
Hi there,
Is this error appeared on all your player lists? Which php version are you using? 8 or 8.1?
Thanks,
Savvas
Hi,
Error appeared on my frontpage, so I’ve checked error log file and found this entry:
PHP Fatal error: Uncaught TypeError: Unsupported operand types: string + int in /β¦/wp-content/plugins/sportspress/includes/class-sp-player-list.php:272
It’s visible in php 8.0 and 8.1 when I change php to 7.4 everything is fine..
Plugin Contributor
Savvas
(@savvasha)
Hi @kuperman87,
Can you share a link to your frontpage? Do you have any player lists appeared on your frontpage? Are you using any performance stats with decimal places?
Thanks,
Savvas
is this really thread resolved?
got a very similar issue here:
Fatal error: Uncaught TypeError: Unsupported operand types: int + string in /wp-content/plugins/sportspress/includes/class-sp-league-table.php:396 Stack
running with PHP v8.3.
(int) $totals[ $team_id ]['eventminutes'] + $minutes
there is happening some type casting for the one int type var and for the concatenated string type var not.
type strictness is an issue now!
so what could get done in between is just casting the second string var too and hope it’s correct without understanding the whole thing behind π
(int) $totals[ $team_id ]['eventminutes'] + (int) $minutes
and then hope the next update will fix it.