Fix file type resolution