Add a guard before deref history.
Add a guard before deref history.

There were certain cases causing togetherjs to break
here when history would be undefined. This was caused
by, for instance, when text in a text box were changed
by script.

youprofit/togetherjs,abhishekgahlot/togetherjs,kyroskoh/togetherjs,m4h4n/togetherjs,TimeTravelersHackedMe/togetherjs,shamim8888/togetherjs,TimeTravelersHackedMe/togetherjs,hhzplst/togetherjs,shamim8888/togetherjs,hhzplst/togetherjs,shamim8888/togetherjs,abhishekgahlot/togetherjs,zartata/togetherjs,youprofit/togetherjs,ericariyanto/togetherjs,TimeTravelersHackMe/togetherjs,youprofit/togetherjs,m4h4n/togetherjs,ericariyanto/togetherjs,zartata/togetherjs,abhishekgahlot/togetherjs,ericariyanto/togetherjs,mcanthony/togetherjs,TimeTravelersHackedMe/togetherjs,kyroskoh/togetherjs,abhishekgahlot/togetherjs,youprofit/togetherjs,hhzplst/togetherjs,ericariyanto/togetherjs,shamim8888/togetherjs,zartata/togetherjs,kyroskoh/togetherjs,zartata/togetherjs,hhzplst/togetherjs,kyroskoh/togetherjs,m4h4n/togetherjs,TimeTravelersHackMe/togetherjs,m4h4n/togetherjs,mcanthony/togetherjs,mcanthony/togetherjs,TimeTravelersHackMe/togetherjs,mcanthony/togetherjs,TimeTravelersHackMe/togetherjs,TimeTravelersHackedMe/togetherjs