Skip to content

Commit

Permalink
Filtering only folders and showing them as per NMC-2893 Task
Browse files Browse the repository at this point in the history
  • Loading branch information
surinder-tsys committed Apr 23, 2024
1 parent 5b9ffc4 commit 0b73173
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@
import java.util.Calendar;
import java.util.List;
import java.util.Stack;
import java.util.stream.Collectors;

import javax.inject.Inject;

Expand Down Expand Up @@ -733,6 +734,10 @@ private void populateDirectoryList() {
if (mFile != null) {
List<OCFile> files = getStorageManager().getFolderContent(mFile, false);

// NMC-2893 Task
// Filtering and showing only files which are folder
files = files.stream().filter(OCFile::isFolder).collect(Collectors.toList());

if (files.isEmpty()) {
setMessageForEmptyList(R.string.file_list_empty_headline, R.string.empty,
R.drawable.uploads);
Expand Down

0 comments on commit 0b73173

Please sign in to comment.