fix(phase-17): align bot handler signatures and resolve merge conflicts

This commit is contained in:
salvacybersec
2026-04-06 17:39:36 +03:00
parent 387d2b5985
commit 41a9ba2a19
3 changed files with 67 additions and 481 deletions

View File

@@ -45,9 +45,10 @@ type Config struct {
// Bot wraps a telego.Bot with KeyHunter command handling and authorization.
type Bot struct {
cfg Config
bot *telego.Bot
cancel context.CancelFunc
cfg Config
bot *telego.Bot
cancel context.CancelFunc
startTime time.Time
rateMu sync.Mutex
rateLimits map[int64]time.Time
@@ -216,38 +217,6 @@ func (b *Bot) replyPlain(ctx context.Context, chatID int64, text string) error {
return err
}
// --- Handler stubs (implemented in Plan 17-03/17-04) ---
func (b *Bot) handleScan(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /scan")
}
func (b *Bot) handleVerify(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /verify")
}
func (b *Bot) handleRecon(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /recon")
}
func (b *Bot) handleStatus(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /status")
}
func (b *Bot) handleStats(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /stats")
}
func (b *Bot) handleProviders(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /providers")
}
func (b *Bot) handleHelp(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /help")
}
func (b *Bot) handleKey(ctx context.Context, msg *telego.Message) {
_ = b.replyPlain(ctx, msg.Chat.ID, "Not yet implemented: /key")
}
// handleSubscribe and handleUnsubscribe are implemented in subscribe.go.
// Command handlers are in handlers.go (17-03).
// Subscribe/unsubscribe handlers are in subscribe.go (17-04).
// Notification dispatcher is in notify.go (17-04).