Rename history object to commandHistory, to avoid collision with window.history