Skip to content

Commit

Permalink
Resolve sonarcloud issues
Browse files Browse the repository at this point in the history
  • Loading branch information
VimukthiRajapaksha committed Oct 28, 2024
1 parent 419a050 commit 3688d64
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -217,12 +217,12 @@ public List<AuthorizationDetailsType> getAuthorizationDetailsTypes(List<Expressi
Integer tenantId)
throws APIResourceMgtException {

try (Connection dbConnection = IdentityDatabaseUtil.getDBConnection(false)) {
FilterQueryBuilder filterQueryBuilder = getAuthorizationDetailsTypesFilterQueryBuilder(expressionNodes);
String query = SQLConstants.GET_AUTHORIZATION_DETAILS_TYPE_BY_TENANT_ID_PREFIX +
filterQueryBuilder.getFilterQuery() + SQLConstants.GET_SCOPES_BY_TENANT_ID_TAIL;
FilterQueryBuilder filterQueryBuilder = getAuthorizationDetailsTypesFilterQueryBuilder(expressionNodes);
final String sqlStmt = SQLConstants.GET_AUTHORIZATION_DETAILS_TYPE_BY_TENANT_ID_PREFIX +
filterQueryBuilder.getFilterQuery() + SQLConstants.GET_SCOPES_BY_TENANT_ID_TAIL;
try (Connection dbConnection = IdentityDatabaseUtil.getDBConnection(false);
PreparedStatement preparedStatement = dbConnection.prepareStatement(sqlStmt)) {

PreparedStatement preparedStatement = dbConnection.prepareStatement(query);
preparedStatement.setInt(1, tenantId);
int filterAttrSize = 0;
if (filterQueryBuilder.getFilterAttributeValue() != null) {
Expand Down

0 comments on commit 3688d64

Please sign in to comment.