Skip to content

Commit 49c348f

Browse files
committed
2 parents f94a232 + e939a50 commit 49c348f

3 files changed

Lines changed: 18 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Changelog
22

3+
## [1.4.1](https://github.com/KarinJS/karin-plugin-basic/compare/v1.4.0...v1.4.1) (2026-01-11)
4+
5+
6+
### Bug Fixes
7+
8+
* 修复正则问题 ([e69c90d](https://github.com/KarinJS/karin-plugin-basic/commit/e69c90de6d17b79df1ff4e35ef815c76fef17f78))
9+
10+
## [1.4.0](https://github.com/KarinJS/karin-plugin-basic/compare/v1.3.6...v1.4.0) (2026-01-11)
11+
12+
13+
### Features
14+
15+
* 添加更新日志等级的命令 ([0dfbab3](https://github.com/KarinJS/karin-plugin-basic/commit/0dfbab3392e7f51d06dcfa61a73ed7dd55e4474e))
16+
317
## [1.3.6](https://github.com/KarinJS/karin-plugin-basic/compare/v1.3.5...v1.3.6) (2026-01-10)
418

519

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@karinjs/plugin-basic",
3-
"version": "1.3.6",
3+
"version": "1.4.1",
44
"description": "Karin的基础插件,提供最基础的功能",
55
"homepage": "https://github.com/KarinJS/karin-plugin-basic",
66
"bugs": {

src/apps/logger.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -366,13 +366,13 @@ export const errorLogViewer = karin.command(/^#错误日志\s*(\d+)?$/, async (e
366366
}
367367
}, { name: '错误日志查看器', perm: 'admin' })
368368

369-
export const updateLogger = karin.command(/^#\s*('trace'|'debug'|'info'|'warn'|'error'|'fatal')$/i, async (e) => {
370-
const match = e.msg.match(/^#\s*('trace'|'debug'|'info'|'warn'|'error'|'fatal')$/i)?.[1].toLowerCase()
369+
export const updateLogger = karin.command(/^#\s*(trace|debug|info|warn|error|fatal)$/i, async (e) => {
370+
const match = e.msg.match(/^#\s*(trace|debug|info|warn|error|fatal)$/i)?.[1].toLowerCase()
371371
if (!match) {
372372
await e.reply('无效的日志等级')
373373
return false
374374
}
375375
logger.level = match
376-
await e.reply(`已将日志等级更新为 ${match.toUpperCase()}`)
376+
await e.reply(`已将日志等级更新为 ${match}`)
377377
return true
378378
}, { name: '更新日志等级', perm: 'admin' })

0 commit comments

Comments
 (0)