1
0
mirror of https://github.com/vikstrous/pirate-get synced 2025-01-09 09:59:51 +01:00

fix bugs with saving magnets and torrents

This commit is contained in:
Viktor Stanchev 2015-08-30 22:54:59 -07:00
parent cfb4a6ce38
commit 82b9c77ff1
2 changed files with 4 additions and 2 deletions

View File

@ -31,7 +31,7 @@ def print(*args, **kwargs):
return builtins.print(*args, **kwargs)
def search_results(mags, sizes, uploaded, local):
def search_results(mags, sizes, uploaded, local=None):
columns = int(os.popen('stty size', 'r').read().split()[1])
cur_color = 'zebra_0'

View File

@ -4,8 +4,10 @@ import gzip
import urllib.request as request
import urllib.parse as parse
import urllib.error
import os.path
import pirate.data
from pirate.print import print
from io import BytesIO
@ -152,4 +154,4 @@ def save_magnets(chosen_links, mags, folder):
print('Saved {:X} in {}'.format(info_hash, file))
with open(file, 'w') as f:
f.write(magnet + '\n')
f.write(magnet + '\n')