diff --git a/src/main/java/net/knarcraft/bookswithoutborders/listener/BookshelfListener.java b/src/main/java/net/knarcraft/bookswithoutborders/listener/BookshelfListener.java index da082a5..f14c2c0 100644 --- a/src/main/java/net/knarcraft/bookswithoutborders/listener/BookshelfListener.java +++ b/src/main/java/net/knarcraft/bookswithoutborders/listener/BookshelfListener.java @@ -83,12 +83,12 @@ public class BookshelfListener implements Listener { private String getBookDescription(BookMeta bookMeta) { String title; String author; - if (!bookMeta.hasTitle()) { + if (!bookMeta.hasTitle() || bookMeta.getTitle() == null) { title = "Untitled"; } else { title = bookMeta.getTitle(); } - if (!bookMeta.hasAuthor()) { + if (!bookMeta.hasAuthor() || bookMeta.getAuthor() == null) { author = "Unknown"; } else { author = bookMeta.getAuthor(); diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index 97fca58..4e9d9d0 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -1,10 +1,10 @@ name: BooksWithoutBorders version: '${project.version}' main: net.knarcraft.bookswithoutborders.BooksWithoutBorders -api-version: 1.20 -prefix: Books Without Borders +api-version: '1.20' +prefix: 'Books Without Borders' authors: [ EpicKnarvik97, AkiraAkiba ] -description: A continuation of the original Books Without Borders +description: 'A continuation of the original Books Without Borders' softdepend: [ Vault ] website: https://www.spigotmc.org/resources/books-without-borders-updated.96069/ dev-url: https://git.knarcraft.net/EpicKnarvik97/Books-Without-Borders