make sure the title is not too long