From 140574f54edc4ff4afab70918af9d2b783570656 Mon Sep 17 00:00:00 2001 From: Ruben Bermudez Date: Wed, 3 Apr 2019 02:18:53 +0100 Subject: [PATCH] Closes #578 --- .../org/telegram/telegrambots/meta/api/objects/Message.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/Message.java b/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/Message.java index d4b7b377..d0f6f3e6 100644 --- a/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/Message.java +++ b/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/Message.java @@ -9,6 +9,7 @@ import org.telegram.telegrambots.meta.api.objects.payments.Invoice; import org.telegram.telegrambots.meta.api.objects.payments.SuccessfulPayment; import org.telegram.telegrambots.meta.api.objects.stickers.Sticker; +import java.util.ArrayList; import java.util.List; /** @@ -282,7 +283,7 @@ public class Message implements BotApiObject { } public List getNewChatMembers() { - return newChatMembers; + return newChatMembers == null ? new ArrayList<>() : newChatMembers; } public User getLeftChatMember() {