Skip to content

Commit

Permalink
Skip invalid protocol names when moving them
Browse files Browse the repository at this point in the history
  • Loading branch information
ajgeiss0702 committed Oct 21, 2023
1 parent 7eb1a75 commit bfe336f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions common/src/main/java/us/ajg0702/queue/common/QueueMain.java
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,10 @@ private void constructMessages() {
List<String> oldProtocolNames = config.getStringList("protocol-names");
for (String oldProtocolName : oldProtocolNames) {
String[] parts = oldProtocolName.split(":");
if(parts.length != 2) {
logger.warn("Invalid old (in the config) protocol name '" + oldProtocolName + "'. Skipping.");
continue;
}
String protocol = parts[0];
String name = parts[1];

Expand Down

0 comments on commit bfe336f

Please sign in to comment.