diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java index c8654c68fb..0831e13e51 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java @@ -256,19 +256,7 @@ public class CraftMetaBook extends CraftMetaItem implements BookMeta { } public List getPages() { - final List copy = ImmutableList.copyOf(pages); - return new AbstractList() { - - @Override - public String get(int index) { - return CraftChatMessage.fromComponent(copy.get(index)); - } - - @Override - public int size() { - return copy.size(); - } - }; + return pages.stream().map(CraftChatMessage::fromComponent).collect(ImmutableList.toImmutableList()); } public void setPages(List pages) {