Move login downloads to default list item

This commit is contained in:
Ruud
2013-06-14 22:08:25 +02:00
parent deffb75c14
commit 2eb938147a
10 changed files with 1 additions and 10 deletions

View File

@@ -275,7 +275,7 @@ class ResultList(list):
'id': 0,
'type': self.provider.type,
'provider': self.provider.getName(),
'download': self.provider.download,
'download': self.provider.loginDownload if self.provider.urls.get('login') else self.provider.download,
'url': '',
'name': '',
'age': 0,

View File

@@ -59,7 +59,6 @@ class FTDWorld(NZBProvider):
'age': self.calculateAge(tryInt(item.get('Created'))),
'size': item.get('Size', 0),
'url': self.urls['download'] % nzb_id,
'download': self.loginDownload,
'detail_url': self.urls['detail'] % nzb_id,
'score': (tryInt(item.get('webPlus', 0)) - tryInt(item.get('webMin', 0))) * 3,
})

View File

@@ -74,7 +74,6 @@ class IPTorrents(TorrentProvider):
'name': torrent_name,
'url': torrent_download_url,
'detail_url': torrent_details_url,
'download': self.loginDownload,
'size': torrent_size,
'seeders': torrent_seeders,
'leechers': torrent_leechers,

View File

@@ -116,7 +116,6 @@ class PassThePopcorn(TorrentProvider):
'leechers': tryInt(torrent['Leechers']),
'score': torrentscore,
'extra_check': extra_check,
'download': self.loginDownload,
})
except:

View File

@@ -67,7 +67,6 @@ class SceneAccess(TorrentProvider):
'size': self.parseSize(result.find('td', attrs = {'class' : 'ttr_size'}).contents[0]),
'seeders': tryInt(result.find('td', attrs = {'class' : 'ttr_seeders'}).find('a').string),
'leechers': tryInt(leechers.string) if leechers else 0,
'download': self.loginDownload,
'get_more_info': self.getMoreInfo,
})

View File

@@ -58,7 +58,6 @@ class SceneHD(TorrentProvider):
'seeders': tryInt(all_cells[10].find('a').string),
'leechers': tryInt(leechers),
'url': self.urls['download'] % torrent_id,
'download': self.loginDownload,
'description': all_cells[1].find('a')['href'],
})

View File

@@ -60,7 +60,6 @@ class TorrentBytes(TorrentProvider):
'name': link.contents[0],
'url': self.urls['download'] % (torrent_id, link.contents[0]),
'detail_url': self.urls['detail'] % torrent_id,
'download': self.loginDownload,
'size': self.parseSize(cells[6].contents[0] + cells[6].contents[2]),
'seeders': tryInt(cells[8].find('span').contents[0]),
'leechers': tryInt(cells[9].find('span').contents[0]),

View File

@@ -51,7 +51,6 @@ class TorrentDay(TorrentProvider):
'size': self.parseSize(torrent.get('size')),
'seeders': tryInt(torrent.get('seed')),
'leechers': tryInt(torrent.get('leech')),
'download': self.loginDownload,
})
def getLoginParams(self):

View File

@@ -59,7 +59,6 @@ class TorrentLeech(TorrentProvider):
'name': link.string,
'url': self.urls['download'] % url['href'],
'detail_url': self.urls['download'] % details['href'],
'download': self.loginDownload,
'size': self.parseSize(result.find_all('td')[4].string),
'seeders': tryInt(result.find('td', attrs = {'class' : 'seeders'}).string),
'leechers': tryInt(result.find('td', attrs = {'class' : 'leechers'}).string),

View File

@@ -59,7 +59,6 @@ class TorrentShack(TorrentProvider):
'name': unicode(link.span.string).translate({ord(u'\xad'): None}),
'url': self.urls['download'] % url['href'],
'detail_url': self.urls['download'] % link['href'],
'download': self.loginDownload,
'size': self.parseSize(result.find_all('td')[4].string),
'seeders': tryInt(result.find_all('td')[6].string),
'leechers': tryInt(result.find_all('td')[7].string),