Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Skip avatar on failure
Signed-off-by: Christopher Ng <[email protected]>
  • Loading branch information
Pytal authored and backportbot-nextcloud[bot] committed May 31, 2022
commit b85f882c23edb565de55ef43613b6e34c41fd028
4 changes: 1 addition & 3 deletions apps/settings/lib/UserMigration/AccountMigrator.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ public function __construct(
* {@inheritDoc}
*/
public function getEstimatedExportSize(IUser $user): int {
$uid = $user->getUID();

$size = 100; // 100KiB for account JSON

try {
Expand All @@ -84,7 +82,7 @@ public function getEstimatedExportSize(IUser $user): int {
$size += $avatarFile->getSize() / 1024;
}
} catch (Throwable $e) {
return 0;
// Skip avatar in size estimate on failure
}

return (int)ceil($size);
Expand Down