modsde uses .format now

This commit is contained in:
enkore 2013-02-23 17:40:23 +01:00
parent 9d5c516d68
commit 040341021c

View File

@ -17,12 +17,15 @@ class ModsDeChecker(IntervalModule):
unread posts in any bookmark in the mods.de forums. unread posts in any bookmark in the mods.de forums.
""" """
settings = ("color", "offset", "format", "username", "password") settings = (
("format", """Use {unread} as the formatter for number of unread posts"""),
"color", "offset", "username", "password"
)
required = ("username", "password") required = ("username", "password")
color = "#7181fe" color = "#7181fe"
offset = 0 offset = 0
format = "%d new posts in bookmarks" format = "{unread} new posts in bookmarks"
login_url = "http://login.mods.de/" login_url = "http://login.mods.de/"
bookmark_url = "http://forum.mods.de/bb/xml/bookmarks.php" bookmark_url = "http://forum.mods.de/bb/xml/bookmarks.php"
@ -41,7 +44,7 @@ class ModsDeChecker(IntervalModule):
self.output = None self.output = None
else: else:
self.output = { self.output = {
"full_text" : self.format % unread, "full_text" : self.format.format(unread=unread),
"name" : "modsde", "name" : "modsde",
"urgent" : "true", "urgent" : "true",
"color" : self.color "color" : self.color