flip null switch for conditionally adding login protocol to default clients

This commit is contained in:
Josh Cain 2017-03-31 16:20:21 -05:00
parent 0482ec40fd
commit 971f053f13

View file

@ -46,7 +46,7 @@ public class MigrateTo3_0_0 implements Migration {
realm.getClients().stream()
.filter(clientModel -> defaultClients.contains(clientModel.getId()))
.filter(clientModel -> Objects.nonNull(clientModel.getProtocol()))
.filter(clientModel -> Objects.isNull(clientModel.getProtocol()))
.forEach(clientModel -> clientModel.setProtocol("openid-connect"));
ClientModel client = realm.getClientByClientId(ACCOUNT_MANAGEMENT_CLIENT_ID);