Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
Mirai
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
Mirai
Commits
5635509c
Commit
5635509c
authored
May 05, 2020
by
ryoii
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Calculate groupCode, fixes #301
parent
bd742915
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
mirai-core-qqandroid/src/commonMain/kotlin/net/mamoe/mirai/qqandroid/network/protocol/packet/chat/NewContact.kt
...irai/qqandroid/network/protocol/packet/chat/NewContact.kt
+6
-5
No files found.
mirai-core-qqandroid/src/commonMain/kotlin/net/mamoe/mirai/qqandroid/network/protocol/packet/chat/NewContact.kt
View file @
5635509c
...
@@ -2,6 +2,7 @@ package net.mamoe.mirai.qqandroid.network.protocol.packet.chat
...
@@ -2,6 +2,7 @@ package net.mamoe.mirai.qqandroid.network.protocol.packet.chat
import
kotlinx.io.core.ByteReadPacket
import
kotlinx.io.core.ByteReadPacket
import
kotlinx.io.core.readBytes
import
kotlinx.io.core.readBytes
import
net.mamoe.mirai.contact.Group
import
net.mamoe.mirai.event.events.BotInvitedJoinGroupRequestEvent
import
net.mamoe.mirai.event.events.BotInvitedJoinGroupRequestEvent
import
net.mamoe.mirai.event.events.MemberJoinRequestEvent
import
net.mamoe.mirai.event.events.MemberJoinRequestEvent
import
net.mamoe.mirai.event.events.NewFriendRequestEvent
import
net.mamoe.mirai.event.events.NewFriendRequestEvent
...
@@ -51,7 +52,7 @@ internal class NewContact {
...
@@ -51,7 +52,7 @@ internal class NewContact {
struct
.
msgSeq
,
struct
.
msgSeq
,
msgAdditional
,
msgAdditional
,
struct
.
reqUin
,
struct
.
reqUin
,
groupCode
,
Group
.
calculateGroupUinByGroupCode
(
groupCode
)
,
reqUinNick
reqUinNick
)
)
}
}
...
@@ -141,7 +142,7 @@ internal class NewContact {
...
@@ -141,7 +142,7 @@ internal class NewContact {
bot
,
bot
,
struct
.
msgSeq
,
struct
.
msgSeq
,
actionUin
,
actionUin
,
groupCode
,
Group
.
calculateGroupUinByGroupCode
(
groupCode
)
,
groupName
,
groupName
,
actionUinNick
actionUinNick
)
)
...
@@ -152,7 +153,7 @@ internal class NewContact {
...
@@ -152,7 +153,7 @@ internal class NewContact {
struct
.
msgSeq
,
struct
.
msgSeq
,
msgAdditional
,
msgAdditional
,
struct
.
reqUin
,
struct
.
reqUin
,
groupCode
,
Group
.
calculateGroupUinByGroupCode
(
groupCode
)
,
groupName
,
groupName
,
reqUinNick
reqUinNick
)
)
...
@@ -180,7 +181,7 @@ internal class NewContact {
...
@@ -180,7 +181,7 @@ internal class NewContact {
true
->
11
// accept
true
->
11
// accept
false
->
12
// reject
false
->
12
// reject
},
},
groupCode
=
event
.
groupId
,
groupCode
=
Group
.
calculateGroupCodeByGroupUin
(
event
.
groupId
)
,
msg
=
""
,
msg
=
""
,
remark
=
""
,
remark
=
""
,
blacklist
=
blackList
blacklist
=
blackList
...
@@ -207,7 +208,7 @@ internal class NewContact {
...
@@ -207,7 +208,7 @@ internal class NewContact {
Structmsg
.
ReqSystemMsgAction
(
Structmsg
.
ReqSystemMsgAction
(
actionInfo
=
Structmsg
.
SystemMsgActionInfo
(
actionInfo
=
Structmsg
.
SystemMsgActionInfo
(
type
=
if
(
accept
)
11
else
12
,
type
=
if
(
accept
)
11
else
12
,
groupCode
=
event
.
groupId
groupCode
=
Group
.
calculateGroupCodeByGroupUin
(
event
.
groupId
)
),
),
groupMsgType
=
2
,
groupMsgType
=
2
,
language
=
1000
,
language
=
1000
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment