1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2024-11-26 03:58:44 +00:00

Merge pull request #708 from InsanusMokrassar/5.0.1

5.0.1
This commit is contained in:
InsanusMokrassar 2023-01-18 23:45:19 +06:00 committed by GitHub
commit c9f3d99cd7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 15 additions and 6 deletions

View File

@ -1,5 +1,14 @@
# TelegramBotAPI changelog # TelegramBotAPI changelog
## 5.0.1
* `Versions`:
* `MicroUtils`: `0.16.4` -> `0.16.6`
* `Ktor`: `2.2.1` -> `2.2.2`
* `Core`:
* Fixes in `SendMediaGroup` request
* Fixes in `SetChatAdministratorCustomTitle` request (thanks to [@madhead](https://github.com/madhead))
## 5.0.0 ## 5.0.0
[Bot API 6.4](https://core.telegram.org/bots/api-changelog#december-30-2022) support! [Bot API 6.4](https://core.telegram.org/bots/api-changelog#december-30-2022) support!

View File

@ -6,4 +6,4 @@ kotlin.incremental=true
kotlin.incremental.js=true kotlin.incremental.js=true
library_group=dev.inmo library_group=dev.inmo
library_version=5.0.0 library_version=5.0.1

View File

@ -8,12 +8,12 @@ javax-activation = "1.1.1"
korlibs = "3.4.0" korlibs = "3.4.0"
uuid = "0.6.0" uuid = "0.6.0"
ktor = "2.2.1" ktor = "2.2.2"
ksp = "1.7.22-1.0.8" ksp = "1.7.22-1.0.8"
kotlin-poet = "1.12.0" kotlin-poet = "1.12.0"
microutils = "0.16.4" microutils = "0.16.6"
github-release-plugin = "2.4.1" github-release-plugin = "2.4.1"
dokka = "1.7.20" dokka = "1.7.20"

View File

@ -18,7 +18,7 @@ data class SetChatAdministratorCustomTitle(
override val resultDeserializer: DeserializationStrategy<Boolean> override val resultDeserializer: DeserializationStrategy<Boolean>
get() = Boolean.serializer() get() = Boolean.serializer()
override val requestSerializer: SerializationStrategy<*> override val requestSerializer: SerializationStrategy<*>
get() = RestrictChatMember.serializer() get() = serializer()
init { init {
if (customTitle.length !in customTitleLength) { if (customTitle.length !in customTitleLength) {

View File

@ -37,7 +37,7 @@ fun <T : MediaGroupPartContent> SendMediaGroup(
protectContent: Boolean = false, protectContent: Boolean = false,
replyToMessageId: MessageId? = null, replyToMessageId: MessageId? = null,
allowSendingWithoutReply: Boolean? = null allowSendingWithoutReply: Boolean? = null
): Request<PossiblySentViaBotCommonMessage<T>> { ): Request<PossiblySentViaBotCommonMessage<MediaGroupContent<T>>> {
if (media.size !in mediaCountInMediaGroup) { if (media.size !in mediaCountInMediaGroup) {
throwRangeError("Count of members in media group", mediaCountInMediaGroup, media.size) throwRangeError("Count of members in media group", mediaCountInMediaGroup, media.size)
} }
@ -70,7 +70,7 @@ fun <T : MediaGroupPartContent> SendMediaGroup(
data, data,
SendMediaGroupFiles(files) SendMediaGroupFiles(files)
) )
}) as Request<PossiblySentViaBotCommonMessage<T>> }) as Request<PossiblySentViaBotCommonMessage<MediaGroupContent<T>>>
} }
/** /**