forked from seba/servefile
Fixed argparse/argv bug
This commit is contained in:
parent
8c90e4142d
commit
b2ce090b55
|
@ -98,7 +98,7 @@ def main():
|
||||||
try:
|
try:
|
||||||
testit = open(args.filename, 'r')
|
testit = open(args.filename, 'r')
|
||||||
testit.close()
|
testit.close()
|
||||||
FileHandler.filePath = sys.argv[1]
|
FileHandler.filePath = args.filename
|
||||||
FileHandler.fileName = os.path.basename(args.filename)
|
FileHandler.fileName = os.path.basename(args.filename)
|
||||||
FileHandler.fileLength = os.stat(args.filename)[ST_SIZE]
|
FileHandler.fileLength = os.stat(args.filename)[ST_SIZE]
|
||||||
except IOError:
|
except IOError:
|
||||||
|
|
Loading…
Reference in New Issue