update title correctly