simplified code
This commit is contained in:
parent
47635ddd18
commit
aa539632c5
1 changed files with 1 additions and 1 deletions
|
@ -42,7 +42,7 @@ if len(sys.argv) > 1 :
|
|||
n = sys.argv[1]
|
||||
if sys.argv[1] == "random" :
|
||||
# try posting a random comic
|
||||
l = max([int(re.sub("[^0-9]", "", i)) for i in os.listdir(seendir)])
|
||||
l = max([int(i) for i in os.listdir(seendir)])
|
||||
n = str(random.randint(1, l))
|
||||
page = request.urlopen(baseurl+"/comic/"+n)
|
||||
else:
|
||||
|
|
Loading…
Reference in a new issue