From 69942003f7dcb0adc0564dd1bc7e47fcd9a11965 Mon Sep 17 00:00:00 2001 From: Isira Seneviratne Date: Fri, 29 Jul 2022 09:21:02 +0530 Subject: [PATCH] Sort tags case-insensitively. --- .../schabi/newpipe/fragments/detail/DescriptionFragment.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/fragments/detail/DescriptionFragment.java b/app/src/main/java/org/schabi/newpipe/fragments/detail/DescriptionFragment.java index bbe52f2e9..bf7f8fa5d 100644 --- a/app/src/main/java/org/schabi/newpipe/fragments/detail/DescriptionFragment.java +++ b/app/src/main/java/org/schabi/newpipe/fragments/detail/DescriptionFragment.java @@ -202,10 +202,9 @@ public class DescriptionFragment extends BaseFragment { private void addTagsMetadataItem(final LayoutInflater inflater, final LinearLayout layout) { if (streamInfo.getTags() != null && !streamInfo.getTags().isEmpty()) { - final ItemMetadataTagsBinding itemBinding = - ItemMetadataTagsBinding.inflate(inflater, layout, false); + final var itemBinding = ItemMetadataTagsBinding.inflate(inflater, layout, false); - streamInfo.getTags().stream().sorted().forEach(tag -> { + streamInfo.getTags().stream().sorted(String.CASE_INSENSITIVE_ORDER).forEach(tag -> { final Chip chip = (Chip) inflater.inflate(R.layout.chip, itemBinding.metadataTagsChips, false); chip.setText(tag);