Render if file is text, Refactor something