Code cleanup
This commit is contained in:
1 parent
3c03e400f0
commit
799299c7cc
214 files changed
+497
-324
No files matched your search
@@ -1,5 +1,6 @@
|
||||
from .main import Trailer
|
||||
|
||||
|
||||
def start():
|
||||
return Trailer()
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ class Trailer(Plugin):
|
||||
destination = os.path.join(group['destination_dir'], filename)
|
||||
if not os.path.isfile(destination):
|
||||
trailer_file = fireEvent('file.download', url = trailer, dest = destination, urlopen_kwargs = {'headers': {'User-Agent': 'Quicktime'}}, single = True)
|
||||
if os.path.getsize(trailer_file) < (1024 * 1024): # Don't trust small trailers (1MB), try next one
|
||||
if os.path.getsize(trailer_file) < (1024 * 1024): # Don't trust small trailers (1MB), try next one
|
||||
os.unlink(trailer_file)
|
||||
continue
|
||||
else:
|
||||
|
||||
Reference in new issue
Block a user