X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fpoke.php;h=2f989dd7d3b07bd415847fe376034911b3be3ea9;hb=f22fe7118d52251dbd0898279ef078b797885ec4;hp=435da4dcd4facd27229767709633724529c690be;hpb=7886de5c393591eaf4e05f2a496a4f40060cb262;p=friendica.git diff --git a/mod/poke.php b/mod/poke.php index 435da4dcd4..2f989dd7d3 100644 --- a/mod/poke.php +++ b/mod/poke.php @@ -1,45 +1,53 @@ -' . ACTIVITY_OBJ_PERSON . '' . $target['name'] . '' . $a->get_baseurl() . '/contact/' . $target['id'] . ''; + $arr['object'] = '' . ACTIVITY_OBJ_PERSON . '' . $target['name'] . '' . System::baseUrl() . '/contact/' . $target['id'] . ''; $arr['object'] .= '' . xmlify('' . "\n"); $arr['object'] .= xmlify('' . "\n"); @@ -127,26 +135,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(System::baseUrl() . '/display/' . $poster['nickname'] . '/' . $item_id), // intval($uid), // intval($item_id) //); - proc_run(PRIORITY_HIGH, "include/notifier.php", "tag", $item_id); + Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id); } call_hooks('post_local_end', $arr); - proc_run(PRIORITY_HIGH, "include/notifier.php", "like", $post_id); + Worker::add(PRIORITY_HIGH, "Notifier", "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 +167,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 = System::baseUrl(); $head_tpl = get_markup_template('poke_head.tpl'); $a->page['htmlhead'] .= replace_macros($head_tpl,array( - '$baseurl' => $a->get_baseurl(true), + '$baseurl' => System::baseUrl(true), '$base' => $base ));