X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fuimport.php;h=d9b040597fdc6c8affe2af20354a437821dba064;hb=5afedb28d4387eef580f7a6602016cc676d8d9e1;hp=e0edb7091d773f61cd149388c2118633293dcea9;hpb=8cd21269ff7b0ca48537b59496a85b06049453aa;p=friendica.git diff --git a/include/uimport.php b/include/uimport.php index e0edb7091d..d9b040597f 100644 --- a/include/uimport.php +++ b/include/uimport.php @@ -1,12 +1,15 @@ "; var_dump($r, $query, mysql_error()); killme(); logger("uimport:insert user : ERROR : " . dba::errorMessage(), LOGGER_NORMAL); notice(t("User creation error")); return; @@ -189,7 +191,7 @@ function import_account(App $a, $file) { } } if ($contact['uid'] == $olduid && $contact['self'] == '0') { - // set contacts 'avatar-date' to NULL_DATE to let poller to update urls + // set contacts 'avatar-date' to NULL_DATE to let worker to update urls $contact["avatar-date"] = NULL_DATE; switch ($contact['network']) { @@ -197,12 +199,6 @@ function import_account(App $a, $file) { case NETWORK_DIASPORA: // send relocate message (below) break; - case NETWORK_ZOT: - /// @TODO handle zot network - break; - case NETWORK_MAIL2: - /// @TODO ? - break; case NETWORK_FEED: case NETWORK_MAIL: // Nothing to do @@ -236,8 +232,6 @@ function import_account(App $a, $file) { } foreach ($account['group_member'] as &$group_member) { - $group_member['uid'] = $newuid; - $import = 0; foreach ($account['group'] as $group) { if ($group['id'] == $group_member['gid'] && isset($group['newid'])) { @@ -265,8 +259,9 @@ function import_account(App $a, $file) { $photo['uid'] = $newuid; $photo['data'] = hex2bin($photo['data']); - $p = new Photo($photo['data'], $photo['type']); - $r = $p->store( + $Image = new Image($photo['data'], $photo['type']); + $r = Photo::store( + $Image, $photo['uid'], $photo['contact-id'], //0 $photo['resource-id'], $photo['filename'], $photo['album'], $photo['scale'], $photo['profile'], //1 $photo['allow_cid'], $photo['allow_gid'], $photo['deny_cid'], $photo['deny_gid']