From e802a98a7a6cd7b0dda52bbffd6817a4f78f74c4 Mon Sep 17 00:00:00 2001 From: Chris Lovering Date: Mon, 19 Aug 2024 12:27:55 +0100 Subject: [PATCH] Parse tuples to all() --- arthur/exts/directory/ldap.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arthur/exts/directory/ldap.py b/arthur/exts/directory/ldap.py index 70fe1ab..1968ba9 100644 --- a/arthur/exts/directory/ldap.py +++ b/arthur/exts/directory/ldap.py @@ -427,19 +427,19 @@ async def sync(self, ctx: commands.Context) -> None: async def setup(bot: KingArthur) -> None: """Add the extension to the bot.""" - if not all(ldap.BONSAI_AVAILABLE, freeipa.BONSAI_AVAILABLE, CONFIG.enable_ldap): + if not all((ldap.BONSAI_AVAILABLE, freeipa.BONSAI_AVAILABLE, CONFIG.enable_ldap)): logger.warning( "Not loading LDAP sync utilities as LDAP dependencies are not available " "or LDAP is disabled by config, see README.md for more." ) return - if not all( + if not all(( CONFIG.ldap_host, CONFIG.ldap_bind_password, CONFIG.ldap_certificate_location, CONFIG.keycloak_address, CONFIG.keycloak_password, - ): + )): logger.warning( "Not loading LDAP sync utilities as one or more LDAP environment variables" "are not set, see README.md for more."