Fix file rename issue