Remove checks that status.is_error in ResultHandler::on_error.

This commit is contained in:
levlam 2023-01-07 23:36:55 +03:00
parent c8acf63e02
commit d0500988ac
2 changed files with 0 additions and 9 deletions

View File

@ -157,7 +157,6 @@ class UploadBackgroundQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
CHECK(file_id_.is_valid());
if (begins_with(status.message(), "FILE_PART_") && ends_with(status.message(), "_MISSING")) {
// TODO td_->background_manager_->on_upload_background_file_part_missing(file_id_, to_integer<int32>(status.message().substr(10)));

View File

@ -934,7 +934,6 @@ class InstallStickerSetQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -969,7 +968,6 @@ class UninstallStickerSetQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -1029,7 +1027,6 @@ class UploadStickerFileQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
if (was_uploaded_) {
CHECK(file_id_.is_valid());
if (begins_with(status.message(), "FILE_PART_") && ends_with(status.message(), "_MISSING")) {
@ -1154,7 +1151,6 @@ class CreateNewStickerSetQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -1189,7 +1185,6 @@ class AddStickerToSetQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -1224,7 +1219,6 @@ class SetStickerSetThumbnailQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -1258,7 +1252,6 @@ class SetStickerPositionQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};
@ -1292,7 +1285,6 @@ class DeleteStickerFromSetQuery final : public Td::ResultHandler {
}
void on_error(Status status) final {
CHECK(status.is_error());
promise_.set_error(std::move(status));
}
};