try fix err

This commit is contained in:
Дмитрий Саенко 2025-10-23 17:24:46 +03:00
parent 8fcb8c549a
commit f13165feea
2 changed files with 3 additions and 2 deletions

View file

@ -5,8 +5,8 @@ import (
"fmt" "fmt"
"strconv" "strconv"
"github.com/mhsanaei/3x-ui/v2/database/model" "github.com/mhsanaei/3x-ui/v2/database/model"
"github.com/mhsanaei/3x-ui/v2/logger"
"github.com/mhsanaei/3x-ui/v2/web/service" "github.com/mhsanaei/3x-ui/v2/web/service"
"github.com/mhsanaei/3x-ui/v2/web/session" "github.com/mhsanaei/3x-ui/v2/web/session"
@ -131,6 +131,7 @@ func (a *InboundController) addInbound(c *gin.Context) {
// delInbound deletes an inbound configuration by its ID. // delInbound deletes an inbound configuration by its ID.
func (a *InboundController) delInbound(c *gin.Context) { func (a *InboundController) delInbound(c *gin.Context) {
id, err := strconv.Atoi(c.Param("id")) id, err := strconv.Atoi(c.Param("id"))
defer logger.Debugf("debug err", err)
if err != nil { if err != nil {
jsonMsg(c, I18nWeb(c, "pages.inbounds.toasts.inboundDeleteSuccess"), err) jsonMsg(c, I18nWeb(c, "pages.inbounds.toasts.inboundDeleteSuccess"), err)
return return

View file

@ -2499,7 +2499,7 @@ func (s *InboundService) syncWithSlaves(method string, path string, contentType
bodyBytes, _ := io.ReadAll(resp.Body) bodyBytes, _ := io.ReadAll(resp.Body)
logger.Warningf("Failed to sync with server %s. Status: %s, Body: %s", server.Name, resp.Status, string(bodyBytes)) logger.Warningf("Failed to sync with server %s. Status: %s, Body: %s", server.Name, resp.Status, string(bodyBytes))
} }
logger.Infof("Synced inbound %v to server %v (%v)", bodyData.(*model.Inbound).Tag, server.Name, resp.Status) //logger.Infof("Synced inbound %v to server %v (%v)", bodyData.(*model.Inbound).Tag, server.Name, resp.Status)
} }
} }