Clarify excuse HTML for the mindays == 0 case.

This commit is contained in:
Colin Watson 2013-09-25 14:44:15 +01:00
parent b723fec4de
commit b78c9693bc

View File

@ -140,7 +140,9 @@ class Excuse(object):
if self.section and string.find(self.section, "/") > -1:
res = res + "<li>Section: %s\n" % (self.section)
if self.daysold != None:
if self.daysold < self.mindays:
if self.mindays == 0:
res = res + ("<li>%d days old\n" % self.daysold)
elif self.daysold < self.mindays:
res = res + ("<li>Too young, only %d of %d days old\n" %
(self.daysold, self.mindays))
else: