From fcf79ded58426db831d52d3b39fe8bc9da4c5cab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Tue, 10 Oct 2023 00:20:35 +0900 Subject: [PATCH 1/8] =?UTF-8?q?fix(cmd/main):=20-update-protocol=20?= =?UTF-8?q?=E4=B8=8D=E4=BF=9D=E5=AD=98=E6=96=B0=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cmd/gocq/main.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/gocq/main.go b/cmd/gocq/main.go index 6ee0d9c9d..736c4f2e8 100644 --- a/cmd/gocq/main.go +++ b/cmd/gocq/main.go @@ -315,7 +315,11 @@ func LoginInteract() { log.Infof("如果登录时出现版本过低错误, 可尝试使用 -update-protocol 参数启动") case !isTokenLogin: _ = device.Protocol.Version().UpdateFromJson(remoteVersion) + err := os.WriteFile(versionFile, remoteVersion, 0644) log.Infof("协议版本已更新: %s -> %s", currentVersionName, remoteVersionName) + if err != nil { + log.Warnln("更新协议版本缓存文件", versionFile, "失败:", err) + } default: log.Infof("检测到协议更新: %s -> %s", currentVersionName, remoteVersionName) log.Infof("由于使用了会话缓存, 无法自动更新协议, 请删除缓存后重试") From e1a4293ee6f424e1cac27ce422636b58ba4a9f00 Mon Sep 17 00:00:00 2001 From: zhullyb Date: Tue, 14 Nov 2023 11:07:27 +0800 Subject: [PATCH 2/8] fix: switch ghproxy.com to mirror.ghproxy.com MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ghproxy.com 已经被墙,根据其网页上的通知应当更换为二级域名 mirror.ghproxy.com,或考虑使用别的反代服务 --- cmd/gocq/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/gocq/main.go b/cmd/gocq/main.go index 736c4f2e8..c24562a35 100644 --- a/cmd/gocq/main.go +++ b/cmd/gocq/main.go @@ -487,7 +487,7 @@ func getRemoteLatestProtocolVersion(protocolType int) ([]byte, error) { } response, err := download.Request{URL: url}.Bytes() if err != nil { - return download.Request{URL: "https://ghproxy.com/" + url}.Bytes() + return download.Request{URL: "https://mirror.ghproxy.com/" + url}.Bytes() } return response, nil } From b8d622bb90bff188601182f4b43efbe669d3a38f Mon Sep 17 00:00:00 2001 From: Akegarasu Date: Thu, 4 Jan 2024 00:55:22 +0800 Subject: [PATCH 3/8] fix #2494 --- coolq/cqcode.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coolq/cqcode.go b/coolq/cqcode.go index c26feae6b..c7d740e16 100644 --- a/coolq/cqcode.go +++ b/coolq/cqcode.go @@ -404,7 +404,7 @@ func ToMessageContent(e []message.IMessageElement, source message.Source) (r []g // ConvertStringMessage 将消息字符串转为消息元素数组 func (bot *CQBot) ConvertStringMessage(spec *onebot.Spec, raw string, sourceType message.SourceType) (r []message.IMessageElement) { elems := msg.ParseString(raw) - return bot.ConvertElements(spec, elems, sourceType, true) + return bot.ConvertElements(spec, elems, sourceType, false) } // ConvertObjectMessage 将消息JSON对象转为消息元素数组 From d25e32023882e709d970568cddaa4711916e7dd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A7=8B=E8=91=89=E6=9D=8F?= Date: Thu, 4 Jan 2024 17:54:12 +0800 Subject: [PATCH 4/8] fix: log error when reading version file. (#2503) --- cmd/gocq/main.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/cmd/gocq/main.go b/cmd/gocq/main.go index c24562a35..eab89f62b 100644 --- a/cmd/gocq/main.go +++ b/cmd/gocq/main.go @@ -255,8 +255,14 @@ func LoginInteract() { versionFile := path.Join(global.VersionsPath, fmt.Sprint(int(cli.Device().Protocol))+".json") if global.PathExists(versionFile) { b, err := os.ReadFile(versionFile) - if err == nil { - _ = cli.Device().Protocol.Version().UpdateFromJson(b) + if err != nil { + log.Warnf("从文件 %s 读取本地版本信息文件出错.", versionFile) + os.Exit(0) + } + err = cli.Device().Protocol.Version().UpdateFromJson(b) + if err != nil { + log.Warnf("从文件 %s 解析本地版本信息出错: %v", versionFile, err) + os.Exit(0) } log.Infof("从文件 %s 读取协议版本 %v.", versionFile, cli.Device().Protocol.Version()) } From 5aca1f450050700378d9c10f97de1904b1320bf0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Mon, 26 Feb 2024 21:54:11 +0900 Subject: [PATCH 5/8] chore: make lint happy --- cmd/gocq/main.go | 4 ++-- server/websocket.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cmd/gocq/main.go b/cmd/gocq/main.go index eab89f62b..3d670ce73 100644 --- a/cmd/gocq/main.go +++ b/cmd/gocq/main.go @@ -348,7 +348,7 @@ func LoginInteract() { } var times uint = 1 // 重试次数 var reLoginLock sync.Mutex - cli.DisconnectedEvent.Subscribe(func(q *client.QQClient, e *client.ClientDisconnectedEvent) { + cli.DisconnectedEvent.Subscribe(func(_ *client.QQClient, e *client.ClientDisconnectedEvent) { reLoginLock.Lock() defer reLoginLock.Unlock() times = 1 @@ -461,7 +461,7 @@ func PasswordHashDecrypt(encryptedPasswordHash string, key []byte) ([]byte, erro func newClient() *client.QQClient { c := client.NewClientEmpty() c.UseFragmentMessage = base.ForceFragmented - c.OnServerUpdated(func(bot *client.QQClient, e *client.ServerUpdatedEvent) bool { + c.OnServerUpdated(func(_ *client.QQClient, e *client.ServerUpdatedEvent) bool { if !base.UseSSOAddress { log.Infof("收到服务器地址更新通知, 根据配置文件已忽略.") return false diff --git a/server/websocket.go b/server/websocket.go index baaa471b1..b2b765c16 100644 --- a/server/websocket.go +++ b/server/websocket.go @@ -71,7 +71,7 @@ func (c *wsConn) Close() error { } var upgrader = websocket.Upgrader{ - CheckOrigin: func(r *http.Request) bool { + CheckOrigin: func(_ *http.Request) bool { return true }, } From e06edd2412feea0d8637fd88a045173d7acf623a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 21:54:34 +0900 Subject: [PATCH 6/8] chore(deps): bump golang.org/x/crypto from 0.11.0 to 0.17.0 (#2502) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat(actions): add Check and Close Invalid PR * Update README.md * Update README.md * chore(deps): bump golang.org/x/crypto from 0.11.0 to 0.17.0 Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.11.0 to 0.17.0. - [Commits](https://github.com/golang/crypto/compare/v0.11.0...v0.17.0) --- updated-dependencies: - dependency-name: golang.org/x/crypto dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: 源文雨 <41315874+fumiama@users.noreply.github.com> Co-authored-by: Mrs4s Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/close_pr.yml | 21 +++++++++++++++++++++ .github/workflows/release.yml | 2 +- README.md | 3 +++ go.mod | 8 ++++---- go.sum | 18 ++++++++---------- 5 files changed, 37 insertions(+), 15 deletions(-) create mode 100644 .github/workflows/close_pr.yml diff --git a/.github/workflows/close_pr.yml b/.github/workflows/close_pr.yml new file mode 100644 index 000000000..de72cced4 --- /dev/null +++ b/.github/workflows/close_pr.yml @@ -0,0 +1,21 @@ +name: Check and Close Invalid PR + +on: + pull_request_target: + types: [opened, reopened] + +jobs: + # This workflow closes invalid PR + close_pr: + # The type of runner that the job will run on + runs-on: ubuntu-latest + permissions: write-all + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + - name: Close PR if it is not pointed to dev branch + if: github.event.pull_request.base.ref != 'dev' + uses: superbrothers/close-pull-request@v3 + with: + # Optional. Post a issue comment just before closing a pull request. + comment: "Invalid PR to `non-dev` branch `${{ github.event.pull_request.base.ref }}`." diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 39a7985b1..7fc20b0b8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -name: release +name: Release on: push: diff --git a/README.md b/README.md index 8efa36cbb..2816097b0 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,9 @@ _✨ 基于 [Mirai](https://github.com/mamoe/mirai) 以及 [MiraiGo](https://git 参与贡献

+## 重要信息 +由于QQ官方针对协议库的围追堵截, 不断更新加密方案, 我们已无力继续维护此项目. +建议Bot开发者尽快迁移至无头NTQQ项目 -> https://github.com/Mrs4s/go-cqhttp/issues/2471 ## 兼容性 go-cqhttp 兼容 [OneBot-v11](https://github.com/botuniverse/onebot-11) 绝大多数内容,并在其基础上做了一些扩展,详情请看 go-cqhttp 的文档。 diff --git a/go.mod b/go.mod index 95c58d59f..d1592f2df 100644 --- a/go.mod +++ b/go.mod @@ -20,10 +20,10 @@ require ( github.com/tidwall/gjson v1.15.0 github.com/wdvxdr1123/go-silk v0.0.0-20210316130616-d47b553def60 go.mongodb.org/mongo-driver v1.12.0 - golang.org/x/crypto v0.11.0 + golang.org/x/crypto v0.17.0 golang.org/x/image v0.9.0 - golang.org/x/sys v0.10.0 - golang.org/x/term v0.10.0 + golang.org/x/sys v0.15.0 + golang.org/x/term v0.15.0 golang.org/x/time v0.3.0 gopkg.ilharper.com/x/isatty v1.1.1 gopkg.in/yaml.v3 v3.0.1 @@ -54,7 +54,7 @@ require ( github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d // indirect golang.org/x/mod v0.12.0 // indirect golang.org/x/sync v0.3.0 // indirect - golang.org/x/text v0.11.0 // indirect + golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.11.0 // indirect lukechampine.com/uint128 v1.2.0 // indirect modernc.org/cc/v3 v3.40.0 // indirect diff --git a/go.sum b/go.sum index 3d4873550..2f8ec7953 100644 --- a/go.sum +++ b/go.sum @@ -4,8 +4,6 @@ github.com/FloatTech/ttl v0.0.0-20220715042055-15612be72f5b h1:tvciXWq2nuvTbFeJG github.com/FloatTech/ttl v0.0.0-20220715042055-15612be72f5b/go.mod h1:fHZFWGquNXuHttu9dUYoKuNbm3dzLETnIOnm1muSfDs= github.com/Microsoft/go-winio v0.6.2-0.20230724192519-b29bbd58a65a h1:aU1703IHxupjzipvhu16qYKLMR03e+8WuNR+JMsKfGU= github.com/Microsoft/go-winio v0.6.2-0.20230724192519-b29bbd58a65a/go.mod h1:OZqLNXdYJHmx7aqq/T6wAdFEdoGm5nmIfC4kU7M8P8o= -github.com/Mrs4s/MiraiGo v0.0.0-20230801023408-b4cd7e8f2149 h1:q9w4m+ps0gTyUHLObX6avawN1Rfn0GQwbmEKCZ6WrBo= -github.com/Mrs4s/MiraiGo v0.0.0-20230801023408-b4cd7e8f2149/go.mod h1:mU3fBFU+7eO0kaGes7YRKtzIDtwIU84nSSwTV7NK2b0= github.com/Mrs4s/MiraiGo v0.0.0-20230823050531-a8213e127b2b h1:0GG6kDFgzie0HNdlkrgPwyX4WqUjckTP1xTM4cYaC2g= github.com/Mrs4s/MiraiGo v0.0.0-20230823050531-a8213e127b2b/go.mod h1:mU3fBFU+7eO0kaGes7YRKtzIDtwIU84nSSwTV7NK2b0= github.com/RomiChan/protobuf v0.1.1-0.20230204044148-2ed269a2e54d h1:/Xuj3fIiMY2ls1TwvPKmaqQrtJsPY+c9s+0lOScVHd8= @@ -116,8 +114,8 @@ go.mongodb.org/mongo-driver v1.12.0/go.mod h1:AZkxhPnFJUoH7kZlFkVKucV20K387miPfm golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= -golang.org/x/crypto v0.11.0/go.mod h1:xgJhtzW8F9jGdVFWZESrid1U1bjeNy4zgy5cRr/CIio= +golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= +golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= golang.org/x/image v0.9.0 h1:QrzfX26snvCM20hIhBwuHI/ThTg18b/+kcKdXHvnR+g= golang.org/x/image v0.9.0/go.mod h1:jtrku+n79PfroUbvDdeUWMAI+heR786BofxrbiSF+J0= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= @@ -150,21 +148,22 @@ golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.10.0 h1:SqMFp9UcQJZa+pmYuAKjd9xq1f0j5rLcDIk0mj4qAsA= -golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= +golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.10.0 h1:3R7pNqamzBraeqj/Tj8qt1aQ2HpmlC+Cx/qL/7hn4/c= -golang.org/x/term v0.10.0/go.mod h1:lpqdcUyK/oCiQxvxVrppt5ggO2KCZ5QblwqPnfZ6d5o= +golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= +golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.11.0 h1:LAntKIrcmeSKERyiOh0XMV39LXS8IE9UL2yP7+f5ij4= golang.org/x/text v0.11.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -175,7 +174,6 @@ golang.org/x/tools v0.11.0 h1:EMCa6U9S2LtZXLAMoWiR/R8dAQFRqbAitmbJ2UKhoi8= golang.org/x/tools v0.11.0/go.mod h1:anzJrxPjNtfgiYQYirP2CPGzGLxrH2u2QBhn6Bf3qY8= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.ilharper.com/x/isatty v1.1.1 h1:RAg32Pxq/nIK4AVtdm9RBqxsxZZX1uRKRSS21E5SHMk= gopkg.ilharper.com/x/isatty v1.1.1/go.mod h1:ofpv77Td5qQO6R1dmDd3oNt8TZdRo+l5gYAMxopRyS0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= From 12e0cb4afbe92436adc724d75dde41fcd6fba3fd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 21:56:53 +0900 Subject: [PATCH 7/8] chore(deps): bump golang.org/x/image from 0.9.0 to 0.10.0 (#2484) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat(actions): add Check and Close Invalid PR * Update README.md * Update README.md * chore(deps): bump golang.org/x/image from 0.9.0 to 0.10.0 Bumps [golang.org/x/image](https://github.com/golang/image) from 0.9.0 to 0.10.0. - [Commits](https://github.com/golang/image/compare/v0.9.0...v0.10.0) --- updated-dependencies: - dependency-name: golang.org/x/image dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: 源文雨 <41315874+fumiama@users.noreply.github.com> Co-authored-by: Mrs4s Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index d1592f2df..66f7881ed 100644 --- a/go.mod +++ b/go.mod @@ -21,7 +21,7 @@ require ( github.com/wdvxdr1123/go-silk v0.0.0-20210316130616-d47b553def60 go.mongodb.org/mongo-driver v1.12.0 golang.org/x/crypto v0.17.0 - golang.org/x/image v0.9.0 + golang.org/x/image v0.10.0 golang.org/x/sys v0.15.0 golang.org/x/term v0.15.0 golang.org/x/time v0.3.0 diff --git a/go.sum b/go.sum index 2f8ec7953..29134641b 100644 --- a/go.sum +++ b/go.sum @@ -116,8 +116,8 @@ golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= -golang.org/x/image v0.9.0 h1:QrzfX26snvCM20hIhBwuHI/ThTg18b/+kcKdXHvnR+g= -golang.org/x/image v0.9.0/go.mod h1:jtrku+n79PfroUbvDdeUWMAI+heR786BofxrbiSF+J0= +golang.org/x/image v0.10.0 h1:gXjUUtwtx5yOE0VKWq1CH4IJAClq4UGgUA3i+rpON9M= +golang.org/x/image v0.10.0/go.mod h1:jtrku+n79PfroUbvDdeUWMAI+heR786BofxrbiSF+J0= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= From 730d01c64814baca1286441357a221fd491b2733 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Mon, 26 Feb 2024 21:59:17 +0900 Subject: [PATCH 8/8] chore: make lint happy --- cmd/gocq/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/gocq/main.go b/cmd/gocq/main.go index 3d670ce73..fe0b04066 100644 --- a/cmd/gocq/main.go +++ b/cmd/gocq/main.go @@ -461,7 +461,7 @@ func PasswordHashDecrypt(encryptedPasswordHash string, key []byte) ([]byte, erro func newClient() *client.QQClient { c := client.NewClientEmpty() c.UseFragmentMessage = base.ForceFragmented - c.OnServerUpdated(func(_ *client.QQClient, e *client.ServerUpdatedEvent) bool { + c.OnServerUpdated(func(_ *client.QQClient, _ *client.ServerUpdatedEvent) bool { if !base.UseSSOAddress { log.Infof("收到服务器地址更新通知, 根据配置文件已忽略.") return false