more modules work
This commit is contained in:
@@ -23,7 +23,6 @@ steam_genre_regex = re.compile("Genre:</b>.*?<a.*?>(.+?)</a>")
|
||||
|
||||
# AMAZON
|
||||
amazon_regex = re.compile("ama?zo?n\.(?:de|com)/.*(?:dp|gp/product)/([A-Z0-9]{10})(?:(?:/+)|$)?")
|
||||
# TODO: Make regex more general (de|com)
|
||||
|
||||
# Commands
|
||||
move_regex = re.compile("^moveall (.*)$")
|
||||
@@ -121,8 +120,8 @@ class chatparser(MumoModule):
|
||||
t = isodate.parse_duration(v["contentDetails"]["duration"])
|
||||
try:
|
||||
rate = "%.2f %%" % (
|
||||
(((float(v["statistics"]["dislikeCount"]) / float(
|
||||
v["statistics"]["likeCount"])) - 1.0) * -1.0) * 100.0)
|
||||
(((float(v["statistics"]["dislikeCount"]) / float(
|
||||
v["statistics"]["likeCount"])) - 1.0) * -1.0) * 100.0)
|
||||
except ZeroDivisionError:
|
||||
rate = "No rating possible"
|
||||
self.sendMessage(server, user, message,
|
||||
|
||||
Reference in New Issue
Block a user