messagesApiToTdlib static method

List<int> messagesApiToTdlib(
  1. dynamic message_ids
)

convert messages_api to messages_api_tdlib example:

List<int> messages_api = [1];
List<num> messages_tdlib = TgUtils.messagesApiToTdlib(message_api); // result: [1048576]

Implementation

static List<int> messagesApiToTdlib(message_ids) {
  if (message_ids is List<int>) {
    return message_ids
        .map((message_id) => messageApiToTdlib(message_id).toInt())
        .toList()
        .cast<int>();
  }
  return [];
}