url format improved

This commit is contained in:
mr 2024-10-07 16:47:03 +02:00
parent 208f69ae7e
commit 5d9c922b26

View File

@ -135,7 +135,7 @@ func (p *PeerCache) exec(url string, method tools.METHOD, body map[string]interf
if err != nil { if err != nil {
return err return err
} }
if e, ok := m["error"]; ok && e != "<nil>" { // Check if there is an error in the response if e, ok := m["error"]; ok && e != "<nil>" && e != "" { // Check if there is an error in the response
return errors.New(fmt.Sprintf("%v", m["error"])) return errors.New(fmt.Sprintf("%v", m["error"]))
} }
return nil return nil