summaryrefslogtreecommitdiffstats
path: root/apps/files_encryption/command/migratekeys.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files_encryption/command/migratekeys.php')
-rw-r--r--apps/files_encryption/command/migratekeys.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/apps/files_encryption/command/migratekeys.php b/apps/files_encryption/command/migratekeys.php
index 200d7367da6..d6db1f70892 100644
--- a/apps/files_encryption/command/migratekeys.php
+++ b/apps/files_encryption/command/migratekeys.php
@@ -62,11 +62,17 @@ class MigrateKeys extends Command {
}
$output->writeln("Migrating keys for users on backend <info>$name</info>");
- $users = $backend->getUsers();
- foreach ($users as $user) {
+
+ $limit = 500;
+ $offset = 0;
+ do {
+ $users = $backend->getUsers('', $limit, $offset);
+ foreach ($users as $user) {
$output->writeln(" <info>$user</info>");
$migration->reorganizeFolderStructureForUser($user);
- }
+ }
+ $offset += $limit;
+ } while(count($users) >= $limit);
}
}