fix broken lastdose

This commit is contained in:
mogad0n 2020-09-17 16:42:16 +05:30
parent 8ccd35936d
commit 114f24678d

View File

@ -226,7 +226,7 @@ class Tripsit(callbacks.Plugin):
since_dose = time - dose_time since_dose = time - dose_time
since_dose_seconds = since_dose.total_seconds() since_dose_seconds = since_dose.total_seconds()
since_dose_formatted = utils.str.format('%T', since_dose_seconds) since_dose_formatted = utils.str.format('%T', since_dose_seconds)
re = f"You last dosed {lastdose['dose']} of {lastdose['drug_and_method']} at {dose_time} UTC, {since_dose_formatted} ago" re = f"You last dosed {lastdose['dose']} of {lastdose['drug_name'] }at {dose_time} UTC, {since_dose_formatted} ago"
irc.reply(re) irc.reply(re)
else: else:
irc.error(f'No last dose saved for {msg.nick}') irc.error(f'No last dose saved for {msg.nick}')