Archiviert
1
0

Fix ranks and ticketlog

Signed-off-by: Lixfel <git-5w3l@lixfel.de>
Dieser Commit ist enthalten in:
Lixfel 2024-06-28 09:27:16 +02:00
Ursprung 47f29e8bc7
Commit 42dea17ff0
2 geänderte Dateien mit 3 neuen und 3 gelöschten Zeilen

Datei anzeigen

@ -91,11 +91,11 @@ public class DiscordTicketHandler extends ListenerAdapter {
.append("<t:").append(message.getTimeCreated().toInstant().getEpochSecond()).append("> ") .append("<t:").append(message.getTimeCreated().toInstant().getEpochSecond()).append("> ")
.append("**").append(message.getAuthor().getName()).append("**: ") .append("**").append(message.getAuthor().getName()).append("**: ")
.append(message.getContentRaw()) .append(message.getContentRaw())
.append("\n"); .append("\n\n");
if(!message.getAttachments().isEmpty()) { if(!message.getAttachments().isEmpty()) {
message.getAttachments().forEach(attachment -> stringBuilder.append(attachment.getUrl())); message.getAttachments().forEach(attachment -> stringBuilder.append(attachment.getUrl()));
stringBuilder.append("\n"); stringBuilder.append("\n\n");
} }
return stringBuilder; return stringBuilder;

Datei anzeigen

@ -33,7 +33,7 @@ import java.util.stream.Collectors;
@UtilityClass @UtilityClass
public class DiscordRanks { public class DiscordRanks {
private final Map<UserPerm.Prefix, String> prefixToPermName = UserPerm.prefixes.entrySet().stream().collect(Collectors.toMap(Map.Entry::getValue, entry -> entry.getKey().name())); private final Map<UserPerm.Prefix, String> prefixToPermName = UserPerm.prefixes.entrySet().stream().collect(Collectors.toMap(Map.Entry::getValue, entry -> entry.getKey().name().toLowerCase()));
public void update(SteamwarUser user) { public void update(SteamwarUser user) {
if (user.getDiscordId() == null) if (user.getDiscordId() == null)