From 4ba4b2976e71d3ba61148962eab35bedf50d140a Mon Sep 17 00:00:00 2001 From: Mario Date: Tue, 11 Jun 2024 07:42:43 +0000 Subject: pass the force argument to the xchan_photo daemon --- Zotlabs/Daemon/Xchan_photo.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'Zotlabs/Daemon') diff --git a/Zotlabs/Daemon/Xchan_photo.php b/Zotlabs/Daemon/Xchan_photo.php index f90d1d726..662fc967c 100644 --- a/Zotlabs/Daemon/Xchan_photo.php +++ b/Zotlabs/Daemon/Xchan_photo.php @@ -8,14 +8,15 @@ class Xchan_photo { static public function run($argc, $argv) { - if ($argc != 3) { + if ($argc < 3) { return; } $url = hex2bin($argv[1]); $xchan = hex2bin($argv[2]); + $force = $argv[3]; - $photos = import_xchan_photo($url, $xchan); + $photos = import_xchan_photo($url, $xchan, false, $force); if ($photos) { $result = q("update xchan set xchan_photo_date = '%s', xchan_photo_l = '%s', xchan_photo_m = '%s', xchan_photo_s = '%s', xchan_photo_mimetype = '%s' where xchan_hash = '%s'", dbescdate(datetime_convert()), @@ -27,8 +28,10 @@ class Xchan_photo { ); if (! $result) { - logger("xchan update failed for $url"); + logger("xchan photo update failed for $url"); } } + + return; } } -- cgit v1.2.3