예제 #1
0
def _lichess_message(league, username, subject, text):
    if league.enable_notifications:
        try:
            lichessapi.send_mail(username, subject, text)
        except lichessapi.ApiClientError as e:
            reason = str(e)
            if "The message was rejected" in reason:
                return
            raise
예제 #2
0
def notify_slack_link(self, lichess_username):
    player = Player.get_or_create(lichess_username)
    email = slackapi.get_user(player.slack_user_id).email
    msg = 'Your lichess account has been successfully linked with the Slack account "%s".' % email
    lichessapi.send_mail(lichess_username, 'Slack Account Linked', msg)
예제 #3
0
def _lichess_message(league, username, subject, text):
    if league.enable_notifications:
        lichessapi.send_mail(username, subject, text)
예제 #4
0
파일: notify.py 프로젝트: cyanfish/heltour
def _lichess_message(league, username, subject, text):
    if league.enable_notifications:
        lichessapi.send_mail(username, subject, text)