Commit fa794ade authored by Piotr Gawron's avatar Piotr Gawron
Browse files

use uniform way of accessing BioEntity identifiers

parent d1f59ee3
......@@ -72,10 +72,10 @@ public class SbmlReactionParser extends SbmlBioEntityParser {
Set<Reaction> used = new HashSet<>();
Map<String, Reaction> reactionById = new HashMap<>();
for (Reaction reaction : reactions) {
if (reactionById.get(reaction.getIdReaction()) != null) {
throw new InvalidInputDataExecption("Duplicated reaction id: " + reaction.getIdReaction());
if (reactionById.get(reaction.getElementId()) != null) {
throw new InvalidInputDataExecption("Duplicated reaction id: " + reaction.getElementId());
}
reactionById.put(reaction.getIdReaction(), reaction);
reactionById.put(reaction.getElementId(), reaction);
}
for (ReactionGlyph glyph : getLayout().getListOfReactionGlyphs()) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment