summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Micha Jay <micha@kalle-l> 2015-05-11 15:13:54 +0200
committerGravatar Micha Jay <micha@kalle-l> 2015-05-11 15:13:54 +0200
commitc86a4ead904d3bb772338a3bf6024260d2bac121 (patch)
tree7ddac45a501caabe83d27d40defe8dffa425cb1a
parent[ClickAndLoad] Version up (diff)
downloadpyload-c86a4ead904d3bb772338a3bf6024260d2bac121.tar.xz
change trafficleft to unlimited when in Penalty-Premium state to ensure continues Downloads
-rw-r--r--module/plugins/accounts/ShareonlineBiz.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/module/plugins/accounts/ShareonlineBiz.py b/module/plugins/accounts/ShareonlineBiz.py
index 8b32ab54d..27371864e 100644
--- a/module/plugins/accounts/ShareonlineBiz.py
+++ b/module/plugins/accounts/ShareonlineBiz.py
@@ -45,8 +45,11 @@ class ShareonlineBiz(Account):
validuntil = float(api['expire_date'])
traffic = float(api['traffic_1d'].split(";")[0])
- maxtraffic = max(maxtraffic, traffic)
- trafficleft = maxtraffic - traffic
+
+ if maxtraffic > traffic:
+ trafficleft = maxtraffic - traffic
+ else:
+ trafficleft = -1
maxtraffic /= 1024 #@TODO: Remove `/ 1024` in 0.4.10
trafficleft /= 1024 #@TODO: Remove `/ 1024` in 0.4.10