Fix(chat-id): Handling unregistered chat ID
All checks were successful
Webhook-Everything/Webhook-Everything/pipeline/head This commit looks good

This commit is contained in:
2025-12-01 02:24:59 +08:00
parent 0c3df1a5f0
commit c9ba5c4312
7 changed files with 44 additions and 198 deletions

View File

@@ -67,7 +67,7 @@ func (env *Env) showRoutes(shortCode string, text string) (bool, *string) {
if len(commandSplitted) > 0 && commandSplitted[0] == "/show" {
var results []WebhookRoute
env.DB.Where(&WebhookRoute{TelegramShortCode: shortCode}).Find(&results)
responseText := "The following webhook URLs were previously registered:"
responseText := "The following webhook URLs were previously registered: "
for _, curr := range results {
baseURL, _ := url.Parse(env.HostURL)
baseURL.Path = path.Join(baseURL.Path, "webhook")