Moved this.rendered = rendered to the end of the statement