fix client api error handling #781

This commit is contained in:
Alireza Ahmadi
2025-09-04 19:56:56 +02:00
parent 97d1694bfa
commit 6aba1354d5
+2 -1
View File
@@ -142,7 +142,8 @@ func (s *ConfigService) Save(obj string, act string, data json.RawMessage, initU
switch obj {
case "clients":
inboundIds, err := s.ClientService.Save(tx, act, data, hostname)
var inboundIds []uint
inboundIds, err = s.ClientService.Save(tx, act, data, hostname)
if err == nil && len(inboundIds) > 0 {
objs = append(objs, "inbounds")
err = s.InboundService.RestartInbounds(tx, inboundIds)