Esempio n. 1
0
def unknown_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print 'No user'
        return
    slack_helper.client.rtm_send_message(channel,
                                         MSG_UNKNOWN.format(user.firstname))
Esempio n. 2
0
def unignore_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print "No user. Unignore gailed."
        return
        # self.ignore_list[user.slackname] = None
    print "Removing {0} from the ignore list".format(user.slackname)
    slack_helper.client.rtm_send_message(channel, MSG_UNIGNORE.format(user.firstname))
Esempio n. 3
0
def unignore_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print 'No user. Unignore gailed.'
        return
    # self.ignore_list[user.slackname] = None
    print 'Removing {0} from the ignore list'.format(user.slackname)
    slack_helper.client.rtm_send_message(channel,
                                         MSG_UNIGNORE.format(user.firstname))
Esempio n. 4
0
def ignore_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print "No user. Ignore failed."
        return
        # if self.ignore_list.get(user.slackname) is not None:
        # 	print 'User already on ignore_list'
        # 	slack_helper.client.rtm_send_message(channel, self.MSG_PREV_IGNORED.format(user.firstname))
        # 	return
        # self.ignore_list[user.slackname] = datetime.now()
    print "Adding {0} to the ignore list".format(user.slackname)
    slack_helper.client.rtm_send_message(channel, MSG_IGNORE.format(user.firstname))
Esempio n. 5
0
def ignore_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print 'No user. Ignore failed.'
        return
    # if self.ignore_list.get(user.slackname) is not None:
    # 	print 'User already on ignore_list'
    # 	slack_helper.client.rtm_send_message(channel, self.MSG_PREV_IGNORED.format(user.firstname))
    # 	return
    # self.ignore_list[user.slackname] = datetime.now()
    print 'Adding {0} to the ignore list'.format(user.slackname)
    slack_helper.client.rtm_send_message(channel,
                                         MSG_IGNORE.format(user.firstname))
Esempio n. 6
0
def unknown_responder(slack_id, channel):
    user = slack_helper.user_from_slack_id(slack_id)
    if not user:
        print "No user"
        return
    slack_helper.client.rtm_send_message(channel, MSG_UNKNOWN.format(user.firstname))