Implemented simple locking for html update.