Avoid calling getElementChecksum if not needed

If there's no checksum in ```serialized```, there's no need to call ```getElementChecksum(rootNode)```.