From 410f37df1b46cde052f0317c957221df6e6a61dd Mon Sep 17 00:00:00 2001 From: Max Kostikov Date: Wed, 3 Apr 2019 00:15:34 +0200 Subject: Fix sync cover photo for clonned channels --- Zotlabs/Module/Cover_photo.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Zotlabs') diff --git a/Zotlabs/Module/Cover_photo.php b/Zotlabs/Module/Cover_photo.php index 224107922..df321ddb6 100644 --- a/Zotlabs/Module/Cover_photo.php +++ b/Zotlabs/Module/Cover_photo.php @@ -208,7 +208,10 @@ logger('gis: ' . print_r($gis,true)); $channel = \App::get_channel(); $this->send_cover_photo_activity($channel,$base_image,$profile); - + + $sync = attach_export_data($channel,$base_image['resource_id']); + if($sync) + build_sync_packet($channel['channel_id'],array('file' => array($sync))); } else @@ -225,7 +228,7 @@ logger('gis: ' . print_r($gis,true)); require_once('include/attach.php'); - $res = attach_store(\App::get_channel(), get_observer_hash(), '', array('album' => t('Cover Photos'), 'hash' => $hash)); + $res = attach_store(\App::get_channel(), get_observer_hash(), '', array('album' => t('Cover Photos'), 'hash' => $hash, 'nosync' => true)); logger('attach_store: ' . print_r($res,true)); -- cgit v1.2.3