1
0
mirror of https://github.com/Mrs4s/go-cqhttp.git synced 2025-06-18 21:45:04 +08:00

db/leveldb: register message.RedBagMessageType

Fixes #1323
This commit is contained in:
wdvxdr 2022-02-06 18:39:22 +08:00
parent f88f51ceed
commit 57d1be0ee5
No known key found for this signature in database
GPG Key ID: 703F8C071DE7A1B6

View File

@ -3,9 +3,11 @@ package leveldb
import (
"bytes"
"encoding/gob"
"github.com/Mrs4s/MiraiGo/utils"
"path"
"github.com/Mrs4s/MiraiGo/message"
"github.com/Mrs4s/MiraiGo/utils"
"github.com/Mrs4s/MiraiGo/binary"
"github.com/pkg/errors"
"github.com/syndtr/goleveldb/leveldb"
@ -35,6 +37,7 @@ func init() {
gob.Register(db.StoredGroupMessage{})
gob.Register(db.StoredPrivateMessage{})
gob.Register(db.StoredGuildChannelMessage{})
gob.Register(message.RedBagMessageType(0))
db.Register("leveldb", func(node yaml.Node) db.Database {
conf := new(config.LevelDBConfig)