Skip to content

Commit

Permalink
Tiny fix to lore-checking.
Browse files Browse the repository at this point in the history
  • Loading branch information
davidcernat committed Jul 30, 2013
1 parent 9972a85 commit b1221ab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/net/aufdemrand/denizen/objects/dItem.java
Expand Up @@ -358,7 +358,7 @@ public int comparesTo(ItemStack item) {
*/
public boolean containsLore(String prefix) {

if (getItemStack().getItemMeta().hasLore()) {
if (getItemStack().hasItemMeta() && getItemStack().getItemMeta().hasLore()) {
for (String itemLore : getItemStack().getItemMeta().getLore()) {
if (itemLore.startsWith(prefix)) {
return true;
Expand Down

0 comments on commit b1221ab

Please sign in to comment.