Commit 9e6a9e9d authored by Efthymia Bika's avatar Efthymia Bika
Browse files

Fix absolute path bug

parent b401c342
......@@ -8,8 +8,12 @@ import errno
path_types = {'reg', 'dir', 'sym', 'fifo', 'sock', 'chr', 'blk'}
def path_join(*args):
return '/'.join(str(x).strip('/') for x in args)
def path_join(base, *args):
slash = base[0:1]
if slash != '/':
slash = ''
base = slash + base.strip('/') + '/'
return base + '/'.join(str(x).strip('/') for x in args)
def timestamp_rfc822_to_iso8601(string):
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment