Skip to content

move _has_redbot condition check under __init__#4

Open
AdiGro wants to merge 1 commit into
japandotorg:v3.2from
AdiGro:patch-2
Open

move _has_redbot condition check under __init__#4
AdiGro wants to merge 1 commit into
japandotorg:v3.2from
AdiGro:patch-2

Conversation

@AdiGro
Copy link
Copy Markdown

@AdiGro AdiGro commented Oct 19, 2024

Class-level statements are executed when the class is defined, which will result in ImportError when RedCommandAdapter is defined despite redbot being optional. This moves the check under __init__ to prevent the same

edit: escaped markdown

Class-level statements are executed when the class is defined, which will result in ImportError when RedCommandAdapter is defined despite redbot being optional. This moves the check under __init__ to prevent the same
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant