Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add guild member timeouts #1061

Merged
merged 3 commits into from
Dec 28, 2021
Merged

Conversation

QPixel
Copy link
Contributor

@QPixel QPixel commented Dec 20, 2021

This PR implements the newly added guild timeout feature

I am unsure about the permissions field, but I believe I followed the set precedent.

@FedorLap2006
Copy link
Collaborator

FedorLap2006 commented Dec 20, 2021

I suggest you to make this PR draft as well, since the PR on docs is not complete, and the feature isn't released publicly yet. We do that often

@QPixel QPixel marked this pull request as draft December 20, 2021 21:32
@FedorLap2006
Copy link
Collaborator

FedorLap2006 commented Dec 20, 2021

@QPixel Fun story, they got it merged before you drafted this, so now you gotta undraft it, lol 😄

@QPixel QPixel marked this pull request as ready for review December 20, 2021 22:02
@CarsonHoffman
Copy link
Collaborator

Both the field name and the JSON property name should be disabled, not disable, no?

@QPixel
Copy link
Contributor Author

QPixel commented Dec 21, 2021

You are completely correct. I must've read it wrong while I was reading the docs pull request.

@QPixel QPixel marked this pull request as draft December 21, 2021 03:02
@QPixel
Copy link
Contributor Author

QPixel commented Dec 21, 2021

I'm converting this back to a draft because I did not account that timeouts can also have reasons. I'm going to implement that and test it, then mark it ready for review again. This should probably be handled in a new pr

@QPixel QPixel marked this pull request as ready for review December 22, 2021 05:19
@tempor1s
Copy link

👋 Hey! Any update on getting this merged? Would love to use it in my project :)

@QPixel
Copy link
Contributor Author

QPixel commented Dec 23, 2021

@CarsonHoffman can I get a new review? I've tested it in my own personal bot and it works fine

@CarsonHoffman
Copy link
Collaborator

I just pushed a commit that reconciles the change I recently made (and was inspired by this PR) to use time.Time in the library instead of our custom Timestamp type (which was somewhat confusing to create manually). I also added the ability to remove the timeout by having the parameter be a pointer, which it doesn't seem like your PR was able to do previously. Let me know what you think of these changes according to your original work with the feature.

@QPixel
Copy link
Contributor Author

QPixel commented Dec 25, 2021

Just tested it on my personal bot, these changes seem to be perfectly fine.

@CarsonHoffman CarsonHoffman merged commit 2926934 into bwmarrin:master Dec 28, 2021
@sentinelb51
Copy link
Contributor

What about including X-Audit-Log-Reason and an optional reason argument?
You could add GuildMuteCreateWithReason since that's like GuildBanCreateWithReason

@QPixel QPixel deleted the feature/guild-timeouts branch December 29, 2021 19:23
@FedorLap2006 FedorLap2006 added this to the v0.24.0 milestone Feb 27, 2022
@FedorLap2006 FedorLap2006 added the feature Feature implementation label Feb 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Feature implementation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants