Fixed an issue with stream to file output path