torann/geoip中使用maxmind_database出错'GeoIp2\Database\Reader' not found

laravel5.7,,,torann/geoip安装好后,修改config/geoip.php中的service为maxmind_database,调用geoip($request->ip())出现错误:

local.ERROR: Class ‘GeoIp2\Database\Reader’ not found

解决办法:安装扩展composer require geoip2/geoip2

点赞