X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fgprobe.php;h=719cfce48635ac4adb109964d9eed19a3f7a498b;hb=3e51ebd4995ee85220132ce1019fd1f712901679;hp=4407fa6d6c5ee77cba0dfcdb40c654a3ecd82c8b;hpb=0548099f6cb89ccb1c798d092b298b3a03fd8d88;p=friendica.git diff --git a/include/gprobe.php b/include/gprobe.php index 4407fa6d6c..719cfce486 100644 --- a/include/gprobe.php +++ b/include/gprobe.php @@ -2,36 +2,14 @@ use \Friendica\Core\Config; -require_once("boot.php"); require_once('include/Scrape.php'); require_once('include/socgraph.php'); +require_once('include/datetime.php'); function gprobe_run(&$argv, &$argc){ - global $a, $db; - - if(is_null($a)) { - $a = new App; - } - - if(is_null($db)) { - @include(".htconfig.php"); - require_once("include/dba.php"); - $db = new dba($db_host, $db_user, $db_pass, $db_data); - unset($db_host, $db_user, $db_pass, $db_data); - }; - - require_once('include/session.php'); - require_once('include/datetime.php'); - - Config::load(); - - $a->set_baseurl(get_config('system','url')); - - load_hooks(); - - if($argc != 2) + if ($argc != 2) { return; - + } $url = hex2bin($argv[1]); $r = q("SELECT `id`, `url`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 1", @@ -74,8 +52,3 @@ function gprobe_run(&$argv, &$argc){ logger("gprobe end for ".normalise_link($url), LOGGER_DEBUG); return; } - -if (array_search(__file__,get_included_files())===0){ - gprobe_run($_SERVER["argv"],$_SERVER["argc"]); - killme(); -}