Can I change a user's nickname based on their ID?

52 Views Asked by At

Is it possible to change a user's nickname using their ID? I tried for a long time to solve this problem, but I never succeeded.

1

There are 1 best solutions below

3
Grinding For Reputation On BEST ANSWER

Why don't you use Member#modifyNickname?

Member member = event.getMember();
member.modifyNickname("Im a Maniac").queue();

Since you haven't provided code I can't tell if this snippet would work, it should if you refactor it as to your needs.