Skip to content

Commit

Permalink
Address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Thisara-Welmilla committed Feb 3, 2025
1 parent 0814e54 commit 4036ef9
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public static class Query {
public static final String UPDATE_AUTHENTICATOR_SQL = "UPDATE IDP_AUTHENTICATOR SET IS_ENABLED = " +
":IS_ENABLED;, DISPLAY_NAME = :DISPLAY_NAME;, IMAGE_URL = :IMAGE_URL;, DESCRIPTION = :DESCRIPTION; " +
"WHERE NAME = :NAME; AND TENANT_ID = :TENANT_ID;";
public static final String GET_AUTHENTICATOR_SQL = "SELECT * FROM IDP_AUTHENTICATOR " +
public static final String GET_USER_DEFINED_LOCAL_AUTHENTICATOR_SQL = "SELECT * FROM IDP_AUTHENTICATOR " +
"WHERE DEFINED_BY = :DEFINED_BY; AND NAME = :NAME; AND TENANT_ID = :TENANT_ID;" +
"AND IDP_ID IN (SELECT ID FROM IDP WHERE IDP.NAME = :IDP_NAME; " +
"AND IDP.TENANT_ID = :TENANT_ID;)";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ private UserDefinedLocalAuthenticatorConfig getUserDefinedLocalAuthenticatorByNa

NamedJdbcTemplate jdbcTemplate = new NamedJdbcTemplate(IdentityDatabaseUtil.getDataSource());
AuthenticatorConfigDaoModel configDaoModel = jdbcTemplate.withTransaction(template ->
template.fetchSingleRecord(Query.GET_AUTHENTICATOR_SQL,
template.fetchSingleRecord(Query.GET_USER_DEFINED_LOCAL_AUTHENTICATOR_SQL,
(resultSet, rowNumber) -> {
UserDefinedLocalAuthenticatorConfig config = getLocalAuthenticatorConfigBasedOnType(
resultSet.getString(Column.AUTHENTICATION_TYPE));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,6 @@ private IdentityProvider populateEndpointConfig(IdentityProvider identityProvide
}
endpointConfigurationManager.resolveEndpointConfig(identityProvider.getFederatedAuthenticatorConfigs()[0],
tenantDomain);
identityProvider.setDefaultAuthenticatorConfig(identityProvider.getFederatedAuthenticatorConfigs()[0]);
return identityProvider;
}

Expand Down

0 comments on commit 4036ef9

Please sign in to comment.