mirror of
https://github.com/J3vb/OwnCord.git
synced 2026-09-03 03:50:00 +03:00
chore: remove unused dmChannelClosePayload and buildDMChannelClose
Fixes golangci-lint unused warnings that would fail CI.
This commit is contained in:
@@ -151,11 +151,6 @@ type dmChannelOpenPayload struct {
|
||||
Recipient dmUserPayload `json:"recipient"`
|
||||
}
|
||||
|
||||
// dmChannelClosePayload is sent when a user closes a DM.
|
||||
type dmChannelClosePayload struct {
|
||||
ChannelID int64 `json:"channel_id"`
|
||||
}
|
||||
|
||||
// dmUserPayload is the public-facing shape for a DM participant in WS events.
|
||||
type dmUserPayload struct {
|
||||
ID int64 `json:"id"`
|
||||
@@ -453,14 +448,6 @@ func buildDMChannelOpen(channelID int64, recipient *db.User) []byte {
|
||||
})
|
||||
}
|
||||
|
||||
// buildDMChannelClose constructs a dm_channel_close event sent to a user.
|
||||
func buildDMChannelClose(channelID int64) []byte {
|
||||
return buildJSON(wsMsg{
|
||||
Type: "dm_channel_close",
|
||||
Payload: dmChannelClosePayload{ChannelID: channelID},
|
||||
})
|
||||
}
|
||||
|
||||
// buildServerRestartMsg constructs a server_restart broadcast.
|
||||
func buildServerRestartMsg(reason string, delaySeconds int) []byte {
|
||||
return buildJSON(wsMsg{
|
||||
|
||||
Reference in New Issue
Block a user