diff options
author | 2022-07-26 00:24:26 +0100 | |
---|---|---|
committer | 2022-08-14 19:43:54 +0100 | |
commit | ddb743856593c431bd6e4d0c440e7e0c7a3ed978 (patch) | |
tree | c826085aa730ef91d4642f02f115d93557209195 | |
parent | noqa false-positive B023 instances (diff) |
Directly return the RedisSession on connection
-rw-r--r-- | bot/__main__.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/bot/__main__.py b/bot/__main__.py index 46850e78e..e0d2e6ad5 100644 --- a/bot/__main__.py +++ b/bot/__main__.py @@ -28,10 +28,9 @@ async def _create_redis_session() -> RedisSession: global_namespace="bot", ) try: - await redis_session.connect() + return await redis_session.connect() except RedisError as e: raise StartupError(e) - return redis_session async def main() -> None: |