mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-19 23:55:19 +00:00
Merge branch 'dev' of /home/macgirvin/z into dev
This commit is contained in:
commit
e6f302229e
3 changed files with 28 additions and 19 deletions
|
@ -1082,15 +1082,15 @@ class Activity {
|
|||
|
||||
$ret['id'] = $i['mid'];
|
||||
|
||||
$token = IConfig::get($i,'ocap','relay');
|
||||
if ($token) {
|
||||
if (defined('USE_BEARCAPS')) {
|
||||
$ret['id'] = 'bear:?u=' . $ret['id'] . '&t=' . $token;
|
||||
}
|
||||
else {
|
||||
$ret['id'] = $ret['id'] . '?token=' . $token;
|
||||
}
|
||||
}
|
||||
// $token = IConfig::get($i,'ocap','relay');
|
||||
// if ($token) {
|
||||
// if (defined('USE_BEARCAPS')) {
|
||||
// $ret['id'] = 'bear:?u=' . $ret['id'] . '&t=' . $token;
|
||||
// }
|
||||
// else {
|
||||
// $ret['id'] = $ret['id'] . '?token=' . $token;
|
||||
// }
|
||||
// }
|
||||
|
||||
$ret['published'] = datetime_convert('UTC','UTC',$i['created'],ATOM_TIME);
|
||||
if ($i['created'] !== $i['edited']) {
|
||||
|
|
|
@ -1440,8 +1440,13 @@ class Item extends Controller {
|
|||
echo json_encode(array('preview' => $o));
|
||||
killme();
|
||||
}
|
||||
if($orig_post)
|
||||
|
||||
// Let 'post_local' event listeners know if this is an edit.
|
||||
// We will unset it immediately afterward.
|
||||
|
||||
if ($orig_post) {
|
||||
$datarray['edit'] = true;
|
||||
}
|
||||
|
||||
// suppress duplicates, *unless* you're editing an existing post. This could get picked up
|
||||
// as a duplicate if you're editing it very soon after posting it initially and you edited
|
||||
|
@ -1465,16 +1470,20 @@ class Item extends Controller {
|
|||
|
||||
call_hooks('post_local',$datarray);
|
||||
|
||||
if(x($datarray,'cancel')) {
|
||||
// This is no longer needed
|
||||
unset($datarray['edit']);
|
||||
|
||||
if (x($datarray,'cancel')) {
|
||||
logger('mod_item: post cancelled by plugin or duplicate suppressed.');
|
||||
if($return_path)
|
||||
if ($return_path) {
|
||||
goaway(z_root() . "/" . $return_path);
|
||||
if($api_source)
|
||||
}
|
||||
if ($api_source) {
|
||||
return ( [ 'success' => false, 'message' => 'operation cancelled' ] );
|
||||
}
|
||||
$json = array('cancel' => 1);
|
||||
$json['reload'] = z_root() . '/' . $_REQUEST['jsreload'];
|
||||
echo json_encode($json);
|
||||
killme();
|
||||
json_return_and_die($json);
|
||||
}
|
||||
|
||||
|
||||
|
|
2
boot.php
2
boot.php
|
@ -17,7 +17,7 @@ use Zotlabs\Daemon\Run;
|
|||
* @brief This file defines some global constants and includes the central App class.
|
||||
*/
|
||||
|
||||
define ( 'STD_VERSION', '21.06.26' );
|
||||
define ( 'STD_VERSION', '21.07.02' );
|
||||
define ( 'ZOT_REVISION', '10.0' );
|
||||
|
||||
define ( 'DB_UPDATE_VERSION', 1248 );
|
||||
|
|
Loading…
Reference in a new issue