feat: code cleanup

This commit is contained in:
zhangdeman committed 2026-01-04 12:49:56 +08:00
1 parent 9f9f62f598
commit ab445203aa
4 files changed
+7 -110

No files matched your search

+1 -4
View File
@@ -9,14 +9,11 @@ package abstract
import (
"context"
"git.zhangdeman.cn/zhangdeman/rate_limit/define"
)
// IRateLimit 流控实现接口约束
//
// Author : go_developer@163.com<白茶清欢>
//
// Date : 11:33 2024/6/20
type IRateLimit interface {
AllowN(ctx context.Context, limitCfg *define.LimitConfig, tokenCnt int) (bool, error) // 申请N个令牌, N >= 0
Reset(ctx context.Context, limitCfg *define.LimitConfig) error // 重置
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.