]> git.mxchange.org Git - friendica.git/blobdiff - mod/poke.php
admin users, don't set account-type if page flag isn't PAGE_NORMAL
[friendica.git] / mod / poke.php
index eb85685d735cf3343a5bd325bc31d4a5204de66b..3148896bc27a8fa624bd4732bdfdf692d9b8f324 100644 (file)
@@ -19,9 +19,9 @@ use Friendica\Core\L10n;
 use Friendica\Core\System;
 use Friendica\Core\Worker;
 use Friendica\Database\DBM;
+use Friendica\Model\Item;
 
 require_once 'include/security.php';
-require_once 'include/bbcode.php';
 require_once 'include/items.php';
 
 function poke_init(App $a) {
@@ -132,21 +132,13 @@ function poke_init(App $a) {
        $arr['object'] .= xmlify('<link rel="photo" type="image/jpeg" href="' . $target['photo'] . '" />' . "\n");
        $arr['object'] .= '</link></object>' . "\n";
 
-       $item_id = item_store($arr);
+       $item_id = Item::insert($arr);
        if($item_id) {
-               //q("UPDATE `item` SET `plink` = '%s' WHERE `uid` = %d AND `id` = %d",
-               //      dbesc(System::baseUrl() . '/display/' . $poster['nickname'] . '/' . $item_id),
-               //      intval($uid),
-               //      intval($item_id)
-               //);
                Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id);
        }
 
-
        Addon::callHooks('post_local_end', $arr);
 
-       Worker::add(PRIORITY_HIGH, "Notifier", "like", $post_id);
-
        return;
 }