always show revoked user ids last!
This commit is contained in:
@@ -716,6 +716,10 @@ public class ProviderHelper {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int compareTo(UserPacketItem o) {
|
public int compareTo(UserPacketItem o) {
|
||||||
|
// revoked keys always come last!
|
||||||
|
if (isRevoked != o.isRevoked) {
|
||||||
|
return isRevoked ? 1 : -1;
|
||||||
|
}
|
||||||
// if one is a user id, but the other isn't, the user id always comes first.
|
// if one is a user id, but the other isn't, the user id always comes first.
|
||||||
// we compare for null values here, so != is the correct operator!
|
// we compare for null values here, so != is the correct operator!
|
||||||
// noinspection NumberEquality
|
// noinspection NumberEquality
|
||||||
@@ -726,10 +730,6 @@ public class ProviderHelper {
|
|||||||
if (isPrimary != o.isPrimary) {
|
if (isPrimary != o.isPrimary) {
|
||||||
return isPrimary ? -1 : 1;
|
return isPrimary ? -1 : 1;
|
||||||
}
|
}
|
||||||
// revoked keys always come last!
|
|
||||||
if (isRevoked != o.isRevoked) {
|
|
||||||
return isRevoked ? 1 : -1;
|
|
||||||
}
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user