fix fallback name?

This commit is contained in:
Chayapak 2023-04-25 19:49:42 +07:00
parent 31ea107bc7
commit dd3444e199
2 changed files with 12 additions and 15 deletions

View file

@ -4,10 +4,7 @@
<option name="autoReloadType" value="SELECTIVE" /> <option name="autoReloadType" value="SELECTIVE" />
</component> </component>
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="50f184fa-7bed-4956-baf5-7586ff26ea08" name="Changes" comment="add reconnect delay to each bot option (optional)"> <list default="true" id="50f184fa-7bed-4956-baf5-7586ff26ea08" name="Changes" comment="change stuff a bit" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/NetMessageCommand.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/NetMessageCommand.java" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" /> <option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" /> <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
@ -98,13 +95,6 @@
<option name="presentableId" value="Default" /> <option name="presentableId" value="Default" />
<updated>1680245437032</updated> <updated>1680245437032</updated>
</task> </task>
<task id="LOCAL-00074" summary="this is why you should test the code before commiting">
<created>1681723861848</created>
<option name="number" value="00074" />
<option name="presentableId" value="LOCAL-00074" />
<option name="project" value="LOCAL" />
<updated>1681723861848</updated>
</task>
<task id="LOCAL-00075" summary="add icu self care&#10;i control uwu uwuw uw uwu wu"> <task id="LOCAL-00075" summary="add icu self care&#10;i control uwu uwuw uw uwu wu">
<created>1681725375832</created> <created>1681725375832</created>
<option name="number" value="00075" /> <option name="number" value="00075" />
@ -441,7 +431,14 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1682404816045</updated> <updated>1682404816045</updated>
</task> </task>
<option name="localTasksCounter" value="123" /> <task id="LOCAL-00123" summary="change stuff a bit">
<created>1682421412680</created>
<option name="number" value="00123" />
<option name="presentableId" value="LOCAL-00123" />
<option name="project" value="LOCAL" />
<updated>1682421412681</updated>
</task>
<option name="localTasksCounter" value="124" />
<servers /> <servers />
</component> </component>
<component name="Vcs.Log.Tabs.Properties"> <component name="Vcs.Log.Tabs.Properties">
@ -456,7 +453,6 @@
</option> </option>
</component> </component>
<component name="VcsManagerConfiguration"> <component name="VcsManagerConfiguration">
<MESSAGE value="fart !!!!" />
<MESSAGE value="sex" /> <MESSAGE value="sex" />
<MESSAGE value="probably improve logquery?" /> <MESSAGE value="probably improve logquery?" />
<MESSAGE value="forgor to set the thread to null" /> <MESSAGE value="forgor to set the thread to null" />
@ -481,7 +477,8 @@
<MESSAGE value="make trusted broadcast log in console" /> <MESSAGE value="make trusted broadcast log in console" />
<MESSAGE value="add connecting message" /> <MESSAGE value="add connecting message" />
<MESSAGE value="add reconnect delay to each bot option (optional)" /> <MESSAGE value="add reconnect delay to each bot option (optional)" />
<option name="LAST_COMMIT_MESSAGE" value="add reconnect delay to each bot option (optional)" /> <MESSAGE value="change stuff a bit" />
<option name="LAST_COMMIT_MESSAGE" value="change stuff a bit" />
</component> </component>
<component name="XSLT-Support.FileAssociations.UIState"> <component name="XSLT-Support.FileAssociations.UIState">
<expand /> <expand />

View file

@ -121,7 +121,7 @@ public class DiscordPlugin {
final String tag = event.getMember().getUser().getDiscriminator(); final String tag = event.getMember().getUser().getDiscriminator();
String name = event.getMember().getNickname(); String name = event.getMember().getNickname();
final String fallbackName = event.getMember().getEffectiveName(); final String fallbackName = event.getAuthor().getName();
if (name == null) name = fallbackName; if (name == null) name = fallbackName;
final Component nameComponent = Component final Component nameComponent = Component