begins to format files correctly