Skip to content

Commit

Permalink
remove
Browse files Browse the repository at this point in the history
  • Loading branch information
colinsl committed Apr 5, 2024
1 parent 5eedec4 commit 6e09e17
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions omnibot/services/slack/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -496,29 +496,6 @@ def get_auth(bot):
return {}


def get_auth(bot):
"""
Get the auth info for the bot.
"""
redis_client = omniredis.get_redis_client()
auth_info = redis_client.hget(f"auth:{bot.team.name}", bot.name)
if auth_info:
return json.loads(auth_info)
auth_info = client(bot).api_call("auth.test")
if auth_info["ok"]:
redis_client.hset(f"auth:{bot.team.name}", bot.name, json.dumps(auth_info))
return auth_info
else:
logger.warning(
"Failed to get auth info",
extra=merge_logging_context(
_get_failure_context(auth_info),
bot.logging_context,
),
)
return {}


def get_name_from_user(user):
profile = user.get("profile", {})
name = profile.get("display_name")
Expand Down

0 comments on commit 6e09e17

Please sign in to comment.