Reset document.title correctly