tg_cli: null message scheduling state by default.

GitOrigin-RevId: 26c144a4a5ce7ab12dc0a6de2556f567301b6b1c
This commit is contained in:
levlam 2019-12-06 04:43:21 +03:00
parent 439ff9be0b
commit 3d4ae6e26c

View File

@ -1242,6 +1242,9 @@ class CliClient final : public Actor {
static td_api::object_ptr<td_api::MessageSchedulingState> as_message_scheduling_state(Slice date) {
date = trim(date);
if (date.empty()) {
return nullptr;
}
auto send_date = to_integer<int32>(date);
if (send_date == -1) {
return td_api::make_object<td_api::messageSchedulingStateSendWhenOnline>();