1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2025-09-16 13:49:26 +00:00

rights copying hotfix

This commit is contained in:
2023-02-06 11:29:07 +06:00
parent 9cd1862300
commit 3be8ddae74
2 changed files with 37 additions and 8 deletions

View File

@@ -190,7 +190,7 @@ interface ChatPermissions {
* Copying current instance as [ChatPermissions], but realizations of this interface may differently override this
* method
*/
fun defaultCopy(
fun copyDefault(
canSendMessages: Boolean? = this.canSendMessages,
canSendAudios: Boolean? = this.canSendAudios,
canSendDocuments: Boolean? = this.canSendDocuments,
@@ -205,13 +205,13 @@ interface ChatPermissions {
canInviteUsers: Boolean? = this.canInviteUsers,
canPinMessages: Boolean? = this.canPinMessages
): ChatPermissions = ChatPermissions(
canSendMessages = canSendPolls,
canSendAudios = null,
canSendDocuments = null,
canSendPhotos = null,
canSendVideos = null,
canSendVideoNotes = null,
canSendVoiceNotes = null,
canSendMessages = canSendMessages,
canSendAudios = canSendAudios,
canSendDocuments = canSendDocuments,
canSendPhotos = canSendPhotos,
canSendVideos = canSendVideos,
canSendVideoNotes = canSendVideoNotes,
canSendVoiceNotes = canSendVoiceNotes,
canSendPolls = canSendPolls,
canSendOtherMessages = canSendOtherMessages,
canAddWebPagePreviews = canAddWebPagePreviews,