Hi @jrfoell again,
I’ve take a deep look into the code and found where is the problem located.
In the file wp-strava/lib/WPStrava/Activity.php row 63:
$meters = $som->distance_inverse( $dist );
You converts $dist
into string, in my case the var_dump
returned string(9) "45,000.00"
But few lines later inside foreach ( $activities as $activity_info )
loop, the var_dump($activity_info->distance)
returns values as floats, i.e.: `float(4528.5)
float(20960.6)
float(134480)
float(111905)`
So the statement if ( $activity_info->distance > $meters )
doesn’t work.
When I typed in the code my meters value as 45000, the plugin works well.
Conclusion: the $som->distance_inverse()
method messed up.
Waiting for fix ??