resolves #824 handle BOM when normalizing source