Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jdk17 #1393

Closed
wants to merge 9 commits into from
Closed

Jdk17 #1393

Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use if instead of switch
  • Loading branch information
ahatius authored Dec 4, 2023
commit d4321971e39ac5435f2a34376d0082bab6012a6c
Original file line number Diff line number Diff line change
Expand Up @@ -166,21 +166,18 @@ public GroupInfo getGroup(GroupId groupId) {
}

public GroupInfo getGroup(final Connection connection, final GroupId groupId) throws SQLException {
switch (groupId) {
case GroupIdV1 groupIdV1 -> {
final var group = getGroup(connection, groupIdV1);
if (groupId instanceof GroupIdV1) {
final var group = getGroup(connection, groupIdV1);
if (group != null) {
return group;
}
return getGroupV2ByV1Id(connection, groupIdV1);
}
case GroupIdV2 groupIdV2 -> {
final var group = getGroup(connection, groupIdV2);
} else if (groupId instanceOf GroupIdV2) {
final var group = getGroup(connection, groupIdV2);
if (group != null) {
return group;
}
return getGroupV1ByV2Id(connection, groupIdV2);
}
}
}

Expand Down