Updating GeoIP2 API?
-
Hello, my site uses the Aelia Currency Switcher plugin (https://aelia.co/shop/currency-switcher-woocommerce/), which loads come common libraries from the Aelia Foundation plugin. Some of those include the GeoIP2 package, just like geoip-detect does.
It’s worked fine for the past 3-4 years, but the Aelia Foundation recently updated to a newer version of the GeoIP2 API. I believe the reason had to do with PHP 8.x compatibility.
Their plugin and this plugin won’t coexist in PHP 8 because of the differing function signatures. Sample error:
PHP Fatal error: Declaration of GeoIp2\Database\Reader::country(string $ipAddress): GeoIp2\Model\Country must be compatible with GeoIp2\ProviderInterface::country($ipAddress) in /var/www/site.com/htdocs/wp-content/plugins/wc-aelia-foundation-classes/src/vendor/geoip2/geoip2/src/Database/Reader.php on line 107
geoip-detect uses version 2.10.0 (2019-12-12), while aelia-foundation upgraded to 2.13.
Are there reasons to not upgrade geoip-detect to use the more recent API? Until this happens, whether officially or if I update my local version, I’m unable to upgrade my Aelia plugins…
Thank you for any suggestions,
Tom
- You must be logged in to reply to this topic.