Handle files directly, fix open uri