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

70 automatically signin user who creates signin #77

Merged

Conversation

c0untingNumbers
Copy link
Contributor

change user to be the person executing command, should be something like i.Member.User.ID
change span context to match execution block (use span instead of span_signinSlug)

@c0untingNumbers c0untingNumbers requested a review from a team as a code owner December 24, 2023 00:13
@1nv8rzim
Copy link
Member

I will look closer when I get home. But looks like you did not change existing interaction response, so it will
cause an error because they are trying to respond to the same interaction.

@c0untingNumbers
Copy link
Contributor Author

Yeah, I am aware of that. Was going to communicate with you about that, just confused about it.

Comment on lines 180 to 190
err = s.InteractionRespond(i.Interaction, &discordgo.InteractionResponse{
Type: discordgo.InteractionResponseChannelMessageWithSource,
Data: &discordgo.InteractionResponseData{
Content: signinMessage(i.Member.User.ID, entSigninType, span.Context()),
Flags: discordgo.MessageFlagsEphemeral,
},
})
if err != nil {
logging.Error(s, err.Error(), i.Member.User, span, logrus.Fields{"error": err})
return
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Message is sent to command user here

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These both use the same interaction; best way to do this is just combine this into the later one

@c0untingNumbers c0untingNumbers merged commit b98b24d into staging Dec 24, 2023
4 checks passed
@1nv8rzim 1nv8rzim deleted the 70-automatically-signin-user-who-creates-signin branch January 10, 2024 22:58
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.

2 participants