fixed a bug where innerHTML update was killing all the dom.