Adapt whitespaces and remove duplicate entry.