From fde636c891f11032e3835274c83d46c82f675522 Mon Sep 17 00:00:00 2001 From: srnyx <25808801+srnyx@users.noreply.github.com> Date: Tue, 2 Apr 2024 17:31:29 -0400 Subject: [PATCH] Bump version (3.0.1) --- build.gradle.kts | 2 +- .../main/java/xyz/srnyx/lazyexample/commands/ServersCmd.java | 5 +++-- library/src/main/java/xyz/srnyx/lazylibrary/LazyEmbed.java | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 96bfcde..b931f97 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -16,7 +16,7 @@ subprojects { apply(plugin = "xyz.srnyx.gradle-galaxy") apply(plugin = "com.github.johnrengelman.shadow") - setupJava("xyz.srnyx", "3.0.0", "A simple library for JDA Discord bots", JavaVersion.VERSION_19) + setupJava("xyz.srnyx", "3.0.1", "A simple library for JDA Discord bots", JavaVersion.VERSION_19) addCompilerArgs("-parameters") repository(Repository.MAVEN_CENTRAL, Repository.JITPACK) diff --git a/example-bot/src/main/java/xyz/srnyx/lazyexample/commands/ServersCmd.java b/example-bot/src/main/java/xyz/srnyx/lazyexample/commands/ServersCmd.java index 274303e..334abef 100644 --- a/example-bot/src/main/java/xyz/srnyx/lazyexample/commands/ServersCmd.java +++ b/example-bot/src/main/java/xyz/srnyx/lazyexample/commands/ServersCmd.java @@ -5,7 +5,6 @@ import com.freya02.botcommands.api.application.ApplicationCommand; import com.freya02.botcommands.api.application.CommandScope; import com.freya02.botcommands.api.application.slash.GlobalSlashEvent; -import com.freya02.botcommands.api.application.slash.GuildSlashEvent; import com.freya02.botcommands.api.application.slash.annotations.JDASlashCommand; import net.dv8tion.jda.api.JDA; @@ -32,7 +31,9 @@ public class ServersCmd extends ApplicationCommand { /** * A constructor is not necessary */ - public ServersCmd() {} + public ServersCmd() { + // Only exists to provide a Javadoc + } /** * A command that lists all servers the bot is in diff --git a/library/src/main/java/xyz/srnyx/lazylibrary/LazyEmbed.java b/library/src/main/java/xyz/srnyx/lazylibrary/LazyEmbed.java index 70c5679..f18d264 100644 --- a/library/src/main/java/xyz/srnyx/lazylibrary/LazyEmbed.java +++ b/library/src/main/java/xyz/srnyx/lazylibrary/LazyEmbed.java @@ -546,7 +546,7 @@ public LazyEmbed setTitle(@Nullable String text, @Nullable String url) { */ @NotNull public LazyEmbed setDescription(@Nullable String description) { - if (description != null && description.length() == 0) description = null; + if (description != null && description.isEmpty()) description = null; builder.setDescription(description); this.description = description; return this;