X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fpoke.php;h=83f3bf1c735894fcfd37b058f45975387ad55e09;hb=6161ceff649fd52cb6cdfe14ebe5fdd35f6854a9;hp=4a643435be229acda46beee3fe352af8ed3e830a;hpb=dfa5183774e24fe2b1a355c9427372d4cd55ea70;p=friendica.git diff --git a/mod/poke.php b/mod/poke.php index 4a643435be..83f3bf1c73 100644 --- a/mod/poke.php +++ b/mod/poke.php @@ -1,45 +1,50 @@ -' . ACTIVITY_OBJ_PERSON . '' . $target['name'] . '' . $a->get_baseurl() . '/contact/' . $target['id'] . ''; + $arr['object'] = '' . ACTIVITY_OBJ_PERSON . '' . $target['name'] . '' . App::get_baseurl() . '/contact/' . $target['id'] . ''; $arr['object'] .= '' . xmlify('' . "\n"); $arr['object'] .= xmlify('' . "\n"); @@ -127,26 +132,26 @@ function poke_init(&$a) { $item_id = item_store($arr); if($item_id) { //q("UPDATE `item` SET `plink` = '%s' WHERE `uid` = %d AND `id` = %d", - // dbesc($a->get_baseurl() . '/display/' . $poster['nickname'] . '/' . $item_id), + // dbesc(App::get_baseurl() . '/display/' . $poster['nickname'] . '/' . $item_id), // intval($uid), // intval($item_id) //); - proc_run('php',"include/notifier.php","tag","$item_id"); + proc_run(PRIORITY_HIGH, "include/notifier.php", "tag", $item_id); } call_hooks('post_local_end', $arr); - proc_run('php',"include/notifier.php","like","$post_id"); + proc_run(PRIORITY_HIGH, "include/notifier.php", "like", $post_id); return; } -function poke_content(&$a) { +function poke_content(App $a) { - if(! local_user()) { + if (! local_user()) { notice( t('Permission denied.') . EOL); return; } @@ -159,18 +164,18 @@ function poke_content(&$a) { intval($_GET['c']), intval(local_user()) ); - if(count($r)) { + if (dbm::is_result($r)) { $name = $r[0]['name']; $id = $r[0]['id']; } } - $base = $a->get_baseurl(); + $base = App::get_baseurl(); $head_tpl = get_markup_template('poke_head.tpl'); $a->page['htmlhead'] .= replace_macros($head_tpl,array( - '$baseurl' => $a->get_baseurl(true), + '$baseurl' => App::get_baseurl(true), '$base' => $base ));