Fixes error outputting when inputting files.