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

Commit 9e74c148 authored by Robert Burns's avatar Robert Burns Committed by Steve Kondik
Browse files

Profiles: Case insensitive duplicate name checking

 - Prevents duplicate names such as Default/default

Change-Id: I479a34192295677653985a66b05becb2d1b6cdf3
parent 271fb62b
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -328,7 +328,12 @@ public class ProfileManagerService extends IProfileManager.Stub {

    @Override
    public boolean profileExistsByName(String profileName) throws RemoteException {
        return mProfileNames.containsKey(profileName);
        for (Map.Entry<String, UUID> entry : mProfileNames.entrySet()) {
            if (entry.getKey().equalsIgnoreCase(profileName)) {
                return true;
            }
        }
        return false;
    }

    @Override