Merge branch 'hotfix/0.13.9'

This commit is contained in:
JackDandy 2018-01-02 15:36:40 +00:00
commit bb45229904
2 changed files with 12 additions and 12 deletions

View file

@ -1,4 +1,9 @@
### 0.13.8 (2017-12-27 15:45:00 UTC)
### 0.13.9 (2018-01-02 15:45:00 UTC)
* Fix marking episode as to upgrade
### 0.13.8 (2017-12-27 15:45:00 UTC)
* Fix HD4Free provider

View file

@ -392,25 +392,20 @@ class wantedQualities(dict):
for q in Quality.qualityStrings:
if 0 >= q:
continue
wanted = [i for i in upgrade_qualities if q < i]
if q not in upgrade_qualities and q in initial_qualities:
# quality is only in initial_qualities
self[qualities][q] = {self.bothlists: False,
self.wantedlist: [i for i in upgrade_qualities if q < i], self.upgradelist: False}
self[qualities][q] = {self.bothlists: False, self.wantedlist: wanted, self.upgradelist: False}
elif q in upgrade_qualities and q in initial_qualities:
# quality is in initial_qualities and upgrade_qualities
self[qualities][q] = {self.bothlists: True,
self.wantedlist: [i for i in upgrade_qualities if q < i], self.upgradelist: True}
self[qualities][q] = {self.bothlists: True, self.wantedlist: wanted, self.upgradelist: True}
elif q in upgrade_qualities:
# quality is only in upgrade_qualities
self[qualities][q] = {self.bothlists: False,
self.wantedlist: [i for i in upgrade_qualities if q < i], self.upgradelist: True}
self[qualities][q] = {self.bothlists: False, self.wantedlist: wanted, self.upgradelist: True}
else:
# quality is not in any selected quality for the show
only_upgrade = q >= max_initial_quality
self[qualities][q] = {self.bothlists: False,
self.wantedlist:
[i for i in (initial_qualities, upgrade_qualities)[only_upgrade] if q < i],
self.upgradelist: only_upgrade}
self[qualities][q] = {self.bothlists: False, self.wantedlist: wanted,
self.upgradelist: (q >= max_initial_quality) and any(upgrade_qualities)}
def __getitem__(self, k):
if k not in self: