When I try with this code in functions.php
file WC_Geolocation::geolocate_ip()
for getting current user country It's working fine.
But when I want to do it the same thing from a plugin, It throwing an error Fatal error: Class 'WC_Geolocation' not found
I have googled it and tried to find any possible solutions but didn't get it, please help me out.
Thanks in advance.