Bug 865803 - allow not setting defaultDirectory (nullcheck before converting to URL), r=joshmoz