Small bug fix in preferences