def masstell(inp, *, names, separator, text, users, message):
"""Send a single message to several users."""
if (names and users) or (text and message):
return lex.masstell.arg_conflict
names, text = names or users, text or message
if not names or not text:
return lex.masstell.missing_args
time = arrow.utcnow().timestamp
db.Tell.insert_many([dict(
recipient=user,
sender=inp.user,
text=text,
time=time,
topic=None) for user in set(names)]).execute()
return lex.tell.send
评论列表
文章目录