git://git.furryclan.net
/
furrycat
/
catbot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f2092a0
)
Start date must be equal to or before end date.
author
CMDR furrycat
<elite@furrycat.net>
Wed, 12 Oct 2016 20:46:43 +0000
(21:46 +0100)
committer
CMDR furrycat
<elite@furrycat.net>
Wed, 12 Oct 2016 20:46:43 +0000
(21:46 +0100)
bot.py
patch
|
blob
|
history
diff --git
a/bot.py
b/bot.py
index
75d4c19
..
35f454d
100755
(executable)
--- a/
bot.py
+++ b/
bot.py
@@
-1259,6
+1259,11
@@
def create_announcement(message, raw):
server = channel.server
create['server_id'] = server.id
+ if 'start_date' in create and 'end_date' in create:
+ if create['start_date'] > create['end_date']:
+ yield from say(message.channel, "Start date must not be before end date!")
+ return
+
announce = yield from can_manage_announcements(message.author, message.channel, 'create', create = create)
if not announce:
return