function item_post(App $a) {
- if ((! local_user()) && (! remote_user()) && (! x($_REQUEST,'commenter'))) {
+ if ((! local_user()) && (! remote_user()) && (! x($_REQUEST, 'commenter'))) {
return;
}
}
// Is this a reply to something?
- $parent = ((x($_REQUEST,'parent')) ? intval($_REQUEST['parent']) : 0);
- $parent_uri = ((x($_REQUEST,'parent_uri')) ? trim($_REQUEST['parent_uri']) : '');
+ $parent = ((x($_REQUEST, 'parent')) ? intval($_REQUEST['parent']) : 0);
+ $parent_uri = ((x($_REQUEST, 'parent_uri')) ? trim($_REQUEST['parent_uri']) : '');
$parent_item = null;
$parent_contact = null;
$objecttype = ACTIVITY_OBJ_COMMENT;
- if (! x($_REQUEST,'type')) {
+ if (! x($_REQUEST, 'type')) {
$_REQUEST['type'] = 'net-comment';
}
if (! dbm::is_result($r)) {
notice( t('Unable to locate original post.') . EOL);
- if (x($_REQUEST,'return')) {
+ if (x($_REQUEST, 'return')) {
goaway($return_path);
}
killme();
logger('mod_item: item_post parent=' . $parent);
}
- $profile_uid = ((x($_REQUEST,'profile_uid')) ? intval($_REQUEST['profile_uid']) : 0);
- $post_id = ((x($_REQUEST,'post_id')) ? intval($_REQUEST['post_id']) : 0);
- $app = ((x($_REQUEST,'source')) ? strip_tags($_REQUEST['source']) : '');
- $extid = ((x($_REQUEST,'extid')) ? strip_tags($_REQUEST['extid']) : '');
- $object = ((x($_REQUEST,'object')) ? $_REQUEST['object'] : '');
+ $profile_uid = ((x($_REQUEST, 'profile_uid')) ? intval($_REQUEST['profile_uid']) : 0);
+ $post_id = ((x($_REQUEST, 'post_id')) ? intval($_REQUEST['post_id']) : 0);
+ $app = ((x($_REQUEST, 'source')) ? strip_tags($_REQUEST['source']) : '');
+ $extid = ((x($_REQUEST, 'extid')) ? strip_tags($_REQUEST['extid']) : '');
+ $object = ((x($_REQUEST, 'object')) ? $_REQUEST['object'] : '');
// Check for multiple posts with the same message id (when the post was created via API)
if (($message_id != '') AND ($profile_uid != 0)) {
// even if the post arrived via API we are considering that it
// originated on this site by default for determining relayability.
- $origin = ((x($_REQUEST,'origin')) ? intval($_REQUEST['origin']) : 1);
+ $origin = ((x($_REQUEST, 'origin')) ? intval($_REQUEST['origin']) : 1);
$notify_type = (($parent) ? 'comment-new' : 'wall-new' );
}
$json = array('cancel' => 1);
- if (x($_REQUEST,'jsreload') && strlen($_REQUEST['jsreload'])) {
+ if (x($_REQUEST, 'jsreload') && strlen($_REQUEST['jsreload'])) {
$json['reload'] = App::get_baseurl() . '/' . $_REQUEST['jsreload'];
}
file_tag_update_pconfig($uid,$categories_old,$categories_new,'category');
proc_run(PRIORITY_HIGH, "include/notifier.php", 'edit_post', $post_id);
- if ((x($_REQUEST,'return')) && strlen($return_path)) {
+ if ((x($_REQUEST, 'return')) && strlen($return_path)) {
logger('return: ' . $return_path);
goaway($return_path);
}