I think these lines should be put out of the report() method. report() is really about converting the value to a "message", it should not do extra work, especially because it may be overriden by the user. Couldn't this be done after l.175, at the same time this.labelNode.innerHTML is updated ?