When a user requests to upload some files, this plugin will verify his/her
upload_files if you select “Verify capability
and MIME type” as “Prevent malicious file uploading”. But some plugins
and themes which support file uploading would tend to define their own
capability, may be for the security reason.
In this case, you should overwrite the slug of capability according to the plugin or theme you are employing.
When a user has own role and capability (e.g.
attach_files), overwrite the
"mu-plugins" (ip-geo-block-mu.php)as Validation timing , you should put your code snippet into
drop-in.phpin Geolocation API folder instead of
functions.php. See My custom functions in “functions.php” doesn’t work. in FAQ for detail.