diff options
author | Mario <mario@mariovavti.com> | 2021-09-30 15:38:49 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-09-30 15:38:49 +0000 |
commit | e48ed9d06d448e50b26ba4ef08accecf4965f769 (patch) | |
tree | daf6f2081764b44b9240869a7bd915e756efc0bb /Zotlabs/Daemon | |
parent | 2c7c9ae2d7f3549a5ec9f7f00373fe5572c2c25d (diff) | |
parent | 6236869ebed317aa06078f606156edcec9f9b55b (diff) | |
download | volse-hubzilla-e48ed9d06d448e50b26ba4ef08accecf4965f769.tar.gz volse-hubzilla-e48ed9d06d448e50b26ba4ef08accecf4965f769.tar.bz2 volse-hubzilla-e48ed9d06d448e50b26ba4ef08accecf4965f769.zip |
Merge branch 'dev' of https://framagit.org/hubzilla/core into dev
Diffstat (limited to 'Zotlabs/Daemon')
-rw-r--r-- | Zotlabs/Daemon/File_importer.php | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/Zotlabs/Daemon/File_importer.php b/Zotlabs/Daemon/File_importer.php index bb12cdf70..28fb172a7 100644 --- a/Zotlabs/Daemon/File_importer.php +++ b/Zotlabs/Daemon/File_importer.php @@ -48,12 +48,18 @@ class File_importer { $j = json_decode($x['body'],true); - if(! is_array($j[0]['attach']) || ! count($j[0]['attach'])) { - PConfig::Set($channel['channel_id'], 'import', 'files', 1); + if(! is_array($j['results'][0]['attach']) || ! count($j['results'][0]['attach'])) { return; } - $r = sync_files($channel,$j); + $r = sync_files($channel, $j['results']); + + PConfig::Set($channel['channel_id'], 'import', 'files_progress', [ + 'files_total' => $j['total'], + 'files_page' => 1, // export page atm returns just one file + 'last_page' => $page, + 'next_cmd' => ['File_importer',sprintf('%d',$page + 1), $channel['channel_address'], urlencode($hz_server)] + ]); $page++; |