diff options
author | Mario <mario@mariovavti.com> | 2021-09-27 21:58:26 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-09-27 21:58:26 +0000 |
commit | 5eb79bd51efbd69d297bbd6f46ee9d1583ec694e (patch) | |
tree | 32f1fce8495644c9ad030dc784dd775752a48853 /Zotlabs/Daemon/File_importer.php | |
parent | d3f5f778a484aadfb4daed26f363e0658f86d9bf (diff) | |
download | volse-hubzilla-5eb79bd51efbd69d297bbd6f46ee9d1583ec694e.tar.gz volse-hubzilla-5eb79bd51efbd69d297bbd6f46ee9d1583ec694e.tar.bz2 volse-hubzilla-5eb79bd51efbd69d297bbd6f46ee9d1583ec694e.zip |
importer daemons: do not call with zap_compat flag and use return instead of kill so that queueworker can go on
Diffstat (limited to 'Zotlabs/Daemon/File_importer.php')
-rw-r--r-- | Zotlabs/Daemon/File_importer.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Zotlabs/Daemon/File_importer.php b/Zotlabs/Daemon/File_importer.php index f3fe785bb..883759a39 100644 --- a/Zotlabs/Daemon/File_importer.php +++ b/Zotlabs/Daemon/File_importer.php @@ -23,18 +23,18 @@ class File_importer { $channel = channelx_by_nick($channel_address); if(! $channel) { logger('filehelper: channel not found'); - killme(); + return; } $headers = [ 'X-API-Token' => random_string(), - 'X-API-Request' => $hz_server . '/api/z/1.0/file/export?f=&zap_compat=1&file_id=' . $attach_id, + 'X-API-Request' => $hz_server . '/api/z/1.0/file/export?f=&file_id=' . $attach_id, 'Host' => $m['host'], - '(request-target)' => 'get /api/z/1.0/file/export?f=&zap_compat=1&file_id=' . $attach_id, + '(request-target)' => 'get /api/z/1.0/file/export?f=&file_id=' . $attach_id, ]; - $headers = HTTPSig::create_sig($headers,$channel['channel_prvkey'],channel_url($channel),true,'sha512'); - $x = z_fetch_url($hz_server . '/api/z/1.0/file/export?f=&zap_compat=1&file_id=' . $attach_id,false,$redirects,[ 'headers' => $headers ]); + $headers = HTTPSig::create_sig($headers,$channel['channel_prvkey'],channel_url($channel),true,'sha512'); + $x = z_fetch_url($hz_server . '/api/z/1.0/file/export?f=&file_id=' . $attach_id,false,$redirects,[ 'headers' => $headers ]); if(! $x['success']) { logger('no API response',LOGGER_DEBUG); @@ -45,6 +45,6 @@ class File_importer { $r = sync_files($channel,[$j]); - killme(); + return; } } |