We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7239e37 commit 06e7f32Copy full SHA for 06e7f32
visidata/path.py
@@ -322,10 +322,10 @@ def with_name(self, name):
322
'Return a sibling Path with *name* as a filename in the same directory.'
323
if self.is_url():
324
urlparts = list(urlparse(self.given))
325
- urlparts[2] = '/'.join(Path(urlparts[2])._parts[1:-1] + [name])
+ urlparts[2] = '/'.join(list(Path(urlparts[2]).parts[1:-1]) + [name])
326
return Path(urlunparse(urlparts))
327
else:
328
- return Path(self._from_parsed_parts(self._drv, self._root, self._parts[:-1] + [name]))
+ return Path(self._from_parsed_parts(self._drv, self._root, list(self.parts[:-1]) + [name]))
329
330
331
class RepeatFile:
0 commit comments