fix wrapper_check() to also work from within admin directory (e.g. cron.php)