summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKHobbits <rob@khobbits.co.uk>2013-01-20 20:06:27 +0000
committerKHobbits <rob@khobbits.co.uk>2013-01-20 20:06:27 +0000
commit67b5b4e06b5a5952d86afe241001c0f5ba589ed4 (patch)
treed5802d8db580475dd99c0b777c7b72ffd26945c9
parent8f9eebf22225f2f1c51382da4f2a6641ee4309da (diff)
downloadEssentials-67b5b4e06b5a5952d86afe241001c0f5ba589ed4.tar
Essentials-67b5b4e06b5a5952d86afe241001c0f5ba589ed4.tar.gz
Essentials-67b5b4e06b5a5952d86afe241001c0f5ba589ed4.tar.lz
Essentials-67b5b4e06b5a5952d86afe241001c0f5ba589ed4.tar.xz
Essentials-67b5b4e06b5a5952d86afe241001c0f5ba589ed4.zip
Fix minor /book bug (Null author)
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandbook.java3
-rw-r--r--Essentials/src/messages.properties2
-rw-r--r--Essentials/src/messages_en.properties2
3 files changed, 4 insertions, 3 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandbook.java b/Essentials/src/com/earth2me/essentials/commands/Commandbook.java
index 1a28a5f86..79fd5fefe 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandbook.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandbook.java
@@ -83,6 +83,7 @@ public class Commandbook extends EssentialsCommand
private boolean isAuthor(BookMeta bmeta, String player)
{
- return bmeta.getAuthor().equalsIgnoreCase(player);
+ String author = bmeta.getAuthor();
+ return author != null && author.equalsIgnoreCase(player);
}
} \ No newline at end of file
diff --git a/Essentials/src/messages.properties b/Essentials/src/messages.properties
index 0727fac9f..d98ecb33b 100644
--- a/Essentials/src/messages.properties
+++ b/Essentials/src/messages.properties
@@ -484,7 +484,7 @@ bookTitleSet=\u00a76Title of the book set to {0}
denyChangeAuthor=\u00a74You cannot change the author of this book
denyChangeTitle=\u00a74You cannot change the title of this book
denyBookEdit=\u00a74You cannot unlock this book
-bookLocked=\u00a7cThis book is now locked
+bookLocked=\u00a76This book is now locked
holdBook=\u00a74You are not holding a writable book
fireworkColor=\u00a74You must apply a color to the firework to add an effect
holdFirework=\u00a74You must be holding a firework to add effects
diff --git a/Essentials/src/messages_en.properties b/Essentials/src/messages_en.properties
index c6b1df86e..9e5e2d8b2 100644
--- a/Essentials/src/messages_en.properties
+++ b/Essentials/src/messages_en.properties
@@ -484,7 +484,7 @@ bookTitleSet=\u00a76Title of the book set to {0}
denyChangeAuthor=\u00a74You cannot change the author of this book
denyChangeTitle=\u00a74You cannot change the title of this book
denyBookEdit=\u00a74You cannot unlock this book
-bookLocked=\u00a7cThis book is now locked
+bookLocked=\u00a76This book is now locked
holdBook=\u00a74You are not holding a writable book
fireworkColor=\u00a74You must apply a color to the firework to add an effect
holdFirework=\u00a74You must be holding a firework to add effects