1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2024-11-29 21:48:43 +00:00

remove FromUser interface from RawChosenInlineResult

This commit is contained in:
vasya 2021-06-29 21:06:46 +03:00
parent 12a35da4b6
commit 38826a5e7e

View File

@ -1,6 +1,5 @@
package dev.inmo.tgbotapi.types.InlineQueries.ChosenInlineResult package dev.inmo.tgbotapi.types.InlineQueries.ChosenInlineResult
import dev.inmo.tgbotapi.CommonAbstracts.FromUser
import dev.inmo.tgbotapi.types.* import dev.inmo.tgbotapi.types.*
import dev.inmo.tgbotapi.types.InlineQueries.abstracts.ChosenInlineResult import dev.inmo.tgbotapi.types.InlineQueries.abstracts.ChosenInlineResult
import dev.inmo.tgbotapi.types.location.StaticLocation import dev.inmo.tgbotapi.types.location.StaticLocation
@ -12,14 +11,14 @@ internal data class RawChosenInlineResult(
@SerialName(resultIdField) @SerialName(resultIdField)
val resultId: InlineQueryIdentifier, //chosen temporary, can be changed val resultId: InlineQueryIdentifier, //chosen temporary, can be changed
@SerialName(fromField) @SerialName(fromField)
override val user: User, val user: User,
@SerialName(queryField) @SerialName(queryField)
val query: String, val query: String,
@SerialName(locationField) @SerialName(locationField)
val location: StaticLocation? = null, val location: StaticLocation? = null,
@SerialName(inlineMessageIdField) @SerialName(inlineMessageIdField)
val inlineMessageId: InlineMessageIdentifier? = null val inlineMessageId: InlineMessageIdentifier? = null
) : FromUser { ) {
val asChosenInlineResult: ChosenInlineResult by lazy { val asChosenInlineResult: ChosenInlineResult by lazy {
location ?.let { location ?.let {
LocationChosenInlineResult(resultId, user, location, inlineMessageId, query) LocationChosenInlineResult(resultId, user, location, inlineMessageId, query)