DaRealTurtyWurty / SuperTurtyBot

A multi-purpose discord bot.
GNU Affero General Public License v3.0
6 stars 10 forks source link

Make rank card use effective name instead of username #251

Closed YodaForce157 closed 5 months ago

YodaForce157 commented 5 months ago

Basically it'll use the global name but if there isn't one it'll use the username, haven't had chance to test this though. but it should be perfectly fine.

DaRealTurtyWurty commented 5 months ago

I'm wondering, can't you just get the effective name from the member?

YodaForce157 commented 5 months ago

I'm pretty sure thats what .getEffectiveName() is doing. If the display name is null, it then returns the username, unless I'm misunderstanding?

DaRealTurtyWurty commented 5 months ago

I'm pretty sure thats what .getEffectiveName() is doing. If the display name is null, it then returns the username, unless I'm misunderstanding?

Nah. Members are per-guild users. So you can have a different name per guild and so the effective name for a member would be

  1. Nickname
  2. Display Name
  3. Username