Skip to content

Commit

Permalink
Merge pull request #16646 from iterate-ch/bugfix/DEEP-11-overview-limit
Browse files Browse the repository at this point in the history
Boxes in result set not required.
  • Loading branch information
ylangisc authored Dec 12, 2024
2 parents 34e7643 + bc9ff22 commit 2c93f91
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ public String getFileId(final Path file) throws BackgroundException {
try {
final OverviewRestControllerApi rest = new OverviewRestControllerApi(session.getClient());
final String companyId = DeepboxIdProvider.this.getFileId(file.getParent());
final Overview overview = rest.getOverview(companyId, chunksize, null);
final Overview overview = rest.getOverview(companyId, 1, null);
return overview.getSharedWithMe().getBoxes().stream().filter(box ->
DeepboxPathNormalizer.name(box.getDeepBoxName()).equals(file.getName())).findFirst().map(BoxEntry::getDeepBoxNodeId).orElse(null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ public AttributedList<Path> list(final Path directory, final ListProgressListene
try {
final AttributedList<Path> list = new AttributedList<>();
final OverviewRestControllerApi rest = new OverviewRestControllerApi(session.getClient());
final Overview overview = rest.getOverview(companyId, chunksize, null);
final Overview overview = rest.getOverview(companyId, 1, null);
for(final BoxEntry box : overview.getSharedWithMe().getBoxes()) {
list.add(new Path(directory,
String.format("%s (%s)", DeepboxPathNormalizer.name(box.getDeepBoxName()), DeepboxPathNormalizer.name(box.getBoxName())),
Expand Down

0 comments on commit 2c93f91

Please sign in to comment.