From 2acfa7e5255e4a107c0f1c91170e4c24e3fea5bc Mon Sep 17 00:00:00 2001 From: zotlabs Date: Thu, 4 Oct 2018 04:18:23 +0000 Subject: regression: double linebreaks in viewsrc output (cherry picked from commit d33c331abd3ae500fc7cdac206ea647c4c71905e) --- Zotlabs/Module/Viewsrc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zotlabs/Module/Viewsrc.php b/Zotlabs/Module/Viewsrc.php index 5900e385a..119990b57 100644 --- a/Zotlabs/Module/Viewsrc.php +++ b/Zotlabs/Module/Viewsrc.php @@ -47,7 +47,7 @@ class Viewsrc extends \Zotlabs\Web\Controller { $content = escape_tags($r[0]['body']); - $o = (($json) ? json_encode($content) : str_replace("\n",'
',$content)); + $o = (($json) ? json_encode($content) : $content); } } -- cgit v1.2.3 From 22fbb512d5be1d95cae7c59f967b978d59557a5a Mon Sep 17 00:00:00 2001 From: zotlabs Date: Wed, 3 Oct 2018 02:42:21 +0000 Subject: do not propagate channel deletion for an already deleted channel. (cherry picked from commit 7c1e99884cf9013d68dcce174e8f8d4f9dac49f7) --- include/channel.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/channel.php b/include/channel.php index 33e438e53..6a934cb82 100644 --- a/include/channel.php +++ b/include/channel.php @@ -2533,6 +2533,12 @@ function channel_remove($channel_id, $local = true, $unset_session = false) { if(! $local) { + if(intval($r[0]['channel_removed'])) { + // already removed. do not propagate deletion of a channel which + // may have been removed locally at some previous time. + return; + } + $r = q("update channel set channel_deleted = '%s', channel_removed = 1 where channel_id = %d", dbesc(datetime_convert()), intval($channel_id) -- cgit v1.2.3