mirror of
https://github.com/IceWhaleTech/CasaOS.git
synced 2025-09-17 17:15:16 +00:00
update http status
This commit is contained in:
parent
8113f51cf7
commit
80c347ac01
@ -36,7 +36,7 @@ func (n *notifyService) SendNotify(path string, message map[string]interface{})
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
if response.StatusCode != http.StatusCreated {
|
if response.StatusCode != http.StatusOK {
|
||||||
return errors.New("failed to send notify (status code: " + fmt.Sprint(response.StatusCode) + ")")
|
return errors.New("failed to send notify (status code: " + fmt.Sprint(response.StatusCode) + ")")
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
@ -58,7 +58,7 @@ func (n *notifyService) SendSystemStatusNotify(message map[string]interface{}) e
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
if response.StatusCode != http.StatusCreated {
|
if response.StatusCode != http.StatusOK {
|
||||||
return errors.New("failed to send notify (status code: " + fmt.Sprint(response.StatusCode) + ")")
|
return errors.New("failed to send notify (status code: " + fmt.Sprint(response.StatusCode) + ")")
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
Loading…
x
Reference in New Issue
Block a user