mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-11-22 08:13:47 +00:00
update version of library
This commit is contained in:
parent
e753db0e71
commit
7471da4ff0
@ -17,7 +17,7 @@ class MultipartRequestCallFactory : AbstractRequestCallFactory() {
|
||||
): Any? = (request as? MultipartRequest) ?.let { castedRequest ->
|
||||
MultiPartFormDataContent(
|
||||
formData {
|
||||
val params = castedRequest.paramsJson.mapWithCommonValues()
|
||||
val params = castedRequest.paramsJson.mapWithCommonValues() - castedRequest.mediaMap.keys
|
||||
for ((key, value) in castedRequest.mediaMap + params) {
|
||||
when (value) {
|
||||
is MultipartFile -> appendInput(
|
||||
|
@ -13,6 +13,7 @@ import kotlinx.serialization.json.JsonObject
|
||||
data class SetChatPhoto (
|
||||
@SerialName(chatIdField)
|
||||
override val chatId: ChatIdentifier,
|
||||
@Transient
|
||||
val photo: MultipartFile = throw IllegalArgumentException("Unfortunately, this type of objects can't be parsed automatically")
|
||||
): ChatRequest, MultipartRequest<Boolean> {
|
||||
override fun method(): String = "setChatPhoto"
|
||||
|
Loading…
Reference in New Issue
Block a user