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

Display user names the same everywhere #281

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

violine1101
Copy link
Member

Purpose

Display new user handles as @violine1101 and old ones as violine1101#8993 everywhere.

This also should fix the issue where messages could not be deleted if you had a new user handle.

Approach

Add a helper function in DiscordUtil to decide how to print the name. Also added two more helper function for consistent setting of embed footers and authors.

Future work

We'll probably need to rework this with the next discord.js update anyway, I presume (though I haven't checked their progress on the matter)

@chandler05
Copy link
Member

I can take a look at this later, but from what I can tell this would still leave #201 as an issue. Not sure if you'd want to figure out a solution for that here, or if you'd rather leave that alone right now.

@violine1101
Copy link
Member Author

I've specifically tested that case and it should work (though only with my second commit)

@mdashlw
Copy link
Contributor

mdashlw commented Aug 30, 2023

Missed this:

.replace( '{{author}}', `@${ message.author.tag }` )


discord.js support for pomelo was added in 14.12.0 (currently using 14.2.0). user.tag now returns username or username#tag whereas this getUserHandle returns @username

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.

4 participants