Skip to content

Conversation

LeviPesin
Copy link
Contributor

Fixes #10313

Summary

Allow thread=None in Webhook.send() by checking thread instead of thread is MISSING.

Checklist

  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes.
  • This PR fixes an issue.
  • This PR adds something new (e.g. new method or parameters).
  • This PR is a breaking change (e.g. methods or parameters removed/renamed)
  • This PR is not a code change (e.g. documentation, README, ...)

@Rapptz
Copy link
Owner

Rapptz commented Sep 21, 2025

Implicit checks like these are bad so I'm not keen on merging this as-is. See also my comment on the issue.

@LeviPesin
Copy link
Contributor Author

I can change them to thread is not MISSING and thread is not None if you like.

@LeviPesin
Copy link
Contributor Author

@Rapptz Should I change the checks in this way? Also, should I also add support for file=None, as it is the only argument except thread which doesn't support it?

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.

Webhook.send() doesn't accept thread=None

2 participants