Skip to content

Commit

Permalink
Adjust nitrogen valence determination
Browse files Browse the repository at this point in the history
Fix #1201 - only allow valence of 5 if there's a nitro group

Signed-off-by: Geoff Hutchison <[email protected]>
  • Loading branch information
ghutchis committed Sep 9, 2023
1 parent 8970c8b commit 70b0636
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion avogadro/core/mdlvalence_p.h
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ static unsigned int atomValence(const unsigned char atomicNumber,
case -1:
return 2;
case 0:
if (numBonds <= 3)
if (numBonds != 5)
return 3;
return 5;
case 1:
Expand Down

0 comments on commit 70b0636

Please sign in to comment.