mirror of
https://github.com/Buriburizaem0n/nezha_domains.git
synced 2026-02-04 12:40:07 +00:00
use plain error type for expected behaviors (#447)
This commit is contained in:
@@ -105,7 +105,7 @@ func editDDNS(c *gin.Context) error {
|
||||
|
||||
var p model.DDNSProfile
|
||||
if err = singleton.DB.First(&p, id).Error; err != nil {
|
||||
return newGormError("%v", err)
|
||||
return fmt.Errorf("profile id %d does not exist", id)
|
||||
}
|
||||
|
||||
p.Name = df.Name
|
||||
|
||||
Reference in New Issue
Block a user