Changed getMessages() return type.