item store hooks

This commit is contained in:
friendica 2013-11-28 18:10:04 -08:00
parent 8e0d3c2d6f
commit eae3327584
2 changed files with 24 additions and 0 deletions

View File

@ -1432,6 +1432,12 @@ function encode_rel_links($links) {
function item_store($arr,$allow_exec = false) {
$d = array('item' => $arr, 'allow_exec' => $allow_exec);
call_hooks('item_store', $d );
$arr = $d['item'];
$allow_exec = $d['allow_exec'];
$ret = array('result' => false, 'item_id' => 0);
if(! $arr['uid']) {
@ -1808,6 +1814,15 @@ function item_store($arr,$allow_exec = false) {
function item_store_update($arr,$allow_exec = false) {
$d = array('item' => $arr, 'allow_exec' => $allow_exec);
call_hooks('item_store_update', $d );
$arr = $d['item'];
$allow_exec = $d['allow_exec'];
$ret = array('result' => false, 'item_id' => 0);
if(! intval($arr['uid'])) {
logger('item_store_update: no uid');

View File

@ -3,6 +3,15 @@
require_once('include/crypto.php');
require_once('include/items.php');
/**
* Red implementation of zot protocol.
*
* https://github.com/friendica/red/wiki/zot
* https://github.com/friendica/red/wiki/Zot---A-High-Level-Overview
*
*/
/**
*
* @function zot_new_uid($channel_nick)