mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-11-26 12:08:43 +00:00
now PassportMessage contains user too
This commit is contained in:
parent
a2ae4f71de
commit
6dcdc2ab7f
@ -2,13 +2,16 @@ package dev.inmo.tgbotapi.types.message
|
||||
|
||||
import com.soywiz.klock.DateTime
|
||||
import dev.inmo.tgbotapi.types.MessageIdentifier
|
||||
import dev.inmo.tgbotapi.types.User
|
||||
import dev.inmo.tgbotapi.types.chat.abstracts.Chat
|
||||
import dev.inmo.tgbotapi.types.message.abstracts.FromUserMessage
|
||||
import dev.inmo.tgbotapi.types.message.abstracts.Message
|
||||
import dev.inmo.tgbotapi.types.passport.PassportData
|
||||
|
||||
data class PassportMessage(
|
||||
override val messageId: MessageIdentifier,
|
||||
override val chat: Chat,
|
||||
override val user: User,
|
||||
override val date: DateTime,
|
||||
val passportData: PassportData
|
||||
) : Message
|
||||
) : Message, FromUserMessage
|
||||
|
@ -329,6 +329,7 @@ internal data class RawMessage(
|
||||
PassportMessage(
|
||||
messageId,
|
||||
chat,
|
||||
from ?: error("For passport must be provided user, but got null"),
|
||||
date.asDate,
|
||||
passport_data
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user