Skip to content

Commit

Permalink
Return error if send secret message result can't be resent.
Browse files Browse the repository at this point in the history
GitOrigin-RevId: 354bf97c1a56c33fc1a30de9d054da84c9c68783
  • Loading branch information
levlam committed Jan 31, 2018
1 parent 9d9957d commit ada8ebb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions td/telegram/SecretChatActor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1710,6 +1710,9 @@ void SecretChatActor::on_outbound_outer_send_message_promise(uint64 state_id, Pr
promise.set_value(Unit()); // Seems like this message is at least stored to binlog already
if (state->send_result_) {
state->send_result_({});
} else {
context_->on_send_message_error(state->message->random_id, Status::Error(400, "Message has already been sent"),
Auto());
}
}

Expand Down

0 comments on commit ada8ebb

Please sign in to comment.