"ChatIdentifier" classes now are "data" classes

This commit is contained in:
InsanusMokrassar 2019-01-21 08:23:27 +08:00
parent bc0606e879
commit f8746e4555
2 changed files with 3 additions and 2 deletions

View File

@ -30,3 +30,4 @@
* Voice
* `MessageContent` now is `ResendableContent`
* Now all media sending factories which contains `thumb` have default `null` value
* `ChatIdentifier` classes now are `data` classes

View File

@ -9,7 +9,7 @@ sealed class ChatIdentifier
* Also used as User Identifier
*/
@Serializable(ChatIdentifierSerializer::class)
class ChatId(
data class ChatId(
val chatId: Identifier
) : ChatIdentifier()
@ -18,7 +18,7 @@ typealias UserId = ChatId
fun Identifier.toChatId(): ChatId = ChatId(this)
@Serializable(ChatIdentifierSerializer::class)
class Username(
data class Username(
val username: String
) : ChatIdentifier() {
init {