fix: Avoid overriding go mod replacements that have already been processed
@@ -97,9 +97,11 @@ public class GoModCliExtractor {
for (String original : replacementData.keySet()) {
String newLine = line.replace(original, replacementData.get(original));
int indexOfLine = modGraphOutput.indexOf(line);
+ if (!line.equals(newLine)) {
modGraphOutput.set(indexOfLine, newLine);
}
}
+ }
return modGraphOutput;
}
