日志优化,增加30条上限

This commit is contained in:
hahwu 2025-06-27 19:23:08 +08:00
parent 8817b293ea
commit d96eaad462

View File

@ -207,6 +207,10 @@ func (f *FriendMod) AddLog(Uid, Type int, Param string) int {
Time: GoUtil.Now(),
Param: Param,
})
if len(f.Log) > 30 {
f.Log = f.Log[len(f.Log)-30:]
}
return f.AutoId
}