Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dd2d4ccd authored by Aishwarya Mallampati's avatar Aishwarya Mallampati
Browse files

Merge strList only if the list is not null.

Bug: 348281209
Test: atest SatelliteManagerTestOnMockService
Flag: EXEMPT bugfix

Change-Id: Ia9805950a7522d89aa2e7ee95a28d7ada31dd4f8
parent 6f2189d1
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -327,8 +327,14 @@ public class SatelliteServiceUtils {
    @NonNull
    public static List<String> mergeStrLists(List<String> strList1, List<String> strList2) {
        Set<String> mergedStrSet = new HashSet<>();
        if (strList1 != null) {
            mergedStrSet.addAll(strList1);
        }

        if (strList2 != null) {
            mergedStrSet.addAll(strList2);
        }

        return mergedStrSet.stream().toList();
    }