Fix calculation of "Number of bytes saved in id attributes"

(bytes safed by renaming the ID attribute istelf were not counted, only those safed by renaming references)
This commit is contained in:
Eduard Braun 2016-08-14 17:08:21 +02:00
parent ac82d2e52b
commit 50498dd60c

View file

@ -715,6 +715,7 @@ def renameID(doc, idFrom, idTo, identifiedElements, referencedIDs):
definingNode.setAttribute("id", idTo)
del identifiedElements[idFrom]
identifiedElements[idTo] = definingNode
num += len(idFrom) - len(idTo)
# Update references to renamed node
referringNodes = referencedIDs.get(idFrom)