aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-04-20 08:09:33 +0000
committerMario <mario@mariovavti.com>2021-04-20 10:36:08 +0200
commitd7f04ff6eee4275569939255fdadfe6448c478da (patch)
treec066d64a5364fb8237dab4a6cd4b329e6ca64586
parent76fd81fad1aa46aa13b3a5dd274b55a2f3b528c5 (diff)
downloadvolse-hubzilla-d7f04ff6eee4275569939255fdadfe6448c478da.tar.gz
volse-hubzilla-d7f04ff6eee4275569939255fdadfe6448c478da.tar.bz2
volse-hubzilla-d7f04ff6eee4275569939255fdadfe6448c478da.zip
when importing a channel, make sure we import the xchan before the hubloc - otherwise we can not verify the hubloc hash
(cherry picked from commit eaf9003ca27c52c571f940e49fcfba6e1c8fe629)
-rw-r--r--Zotlabs/Module/Import.php19
1 files changed, 10 insertions, 9 deletions
diff --git a/Zotlabs/Module/Import.php b/Zotlabs/Module/Import.php
index 8ef24b232..4622a588d 100644
--- a/Zotlabs/Module/Import.php
+++ b/Zotlabs/Module/Import.php
@@ -209,12 +209,6 @@ class Import extends \Zotlabs\Web\Controller {
logger('import step 3');
- if(is_array($data['hubloc'])) {
- import_hublocs($channel,$data['hubloc'],$seize,$moving);
- }
-
- logger('import step 4');
-
// create new hubloc for the new channel at this site
if(array_key_exists('channel',$data)) {
@@ -277,7 +271,7 @@ class Import extends \Zotlabs\Web\Controller {
}
- logger('import step 5');
+ logger('import step 4');
// import xchans and contact photos
@@ -335,7 +329,7 @@ class Import extends \Zotlabs\Web\Controller {
}
- logger('import step 6');
+ logger('import step 5');
// import xchans
$xchans = $data['xchan'];
@@ -404,7 +398,14 @@ class Import extends \Zotlabs\Web\Controller {
}
}
- logger('import step 7');
+ logger('import step 6');
+ }
+
+ logger('import step 7');
+
+ // this must happen after xchans got imported!
+ if(is_array($data['hubloc'])) {
+ import_hublocs($channel,$data['hubloc'],$seize,$moving);
}
$friends = 0;