Fixed bug where the url mangling was messing up if no file was provided