Merge pull request #6092 from JonnyTischbein/issue_drop_item_return_non-frio
Fix return url when dropping post loaded by update_* in non-frio
This commit is contained in:
commit
27dd913fcc
|
@ -410,6 +410,10 @@ function drop_item($id, $return = '')
|
||||||
Item::deleteForUser(['id' => $item['id']], local_user());
|
Item::deleteForUser(['id' => $item['id']], local_user());
|
||||||
|
|
||||||
$return_url = hex2bin($return);
|
$return_url = hex2bin($return);
|
||||||
|
|
||||||
|
// removes update_* from return_url to ignore Ajax refresh
|
||||||
|
$return_url = str_replace("update_", "", $return_url);
|
||||||
|
|
||||||
if (empty($return_url) || strpos($return_url, 'display') !== false) {
|
if (empty($return_url) || strpos($return_url, 'display') !== false) {
|
||||||
$a->internalRedirect('network');
|
$a->internalRedirect('network');
|
||||||
//NOTREACHED
|
//NOTREACHED
|
||||||
|
|
|
@ -7,7 +7,7 @@ use Friendica\Core\L10n;
|
||||||
use Friendica\Core\PConfig;
|
use Friendica\Core\PConfig;
|
||||||
use Friendica\Module\Contact;
|
use Friendica\Module\Contact;
|
||||||
|
|
||||||
function update_contacts_content(App $a)
|
function update_contact_content(App $a)
|
||||||
{
|
{
|
||||||
header("Content-type: text/html");
|
header("Content-type: text/html");
|
||||||
echo "<!DOCTYPE html><html><body>\r\n";
|
echo "<!DOCTYPE html><html><body>\r\n";
|
|
@ -390,7 +390,7 @@ function NavUpdate() {
|
||||||
$('nav').trigger('nav-update', data.result);
|
$('nav').trigger('nav-update', data.result);
|
||||||
|
|
||||||
// start live update
|
// start live update
|
||||||
['network', 'profile', 'community', 'notes', 'display', 'contacts'].forEach(function (src) {
|
['network', 'profile', 'community', 'notes', 'display', 'contact'].forEach(function (src) {
|
||||||
if ($('#live-' + src).length) {
|
if ($('#live-' + src).length) {
|
||||||
liveUpdate(src);
|
liveUpdate(src);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user