mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-28 18:08:51 +03:00
home: imp naming
This commit is contained in:
parent
664ef85c6c
commit
4bc1337cc9
1 changed files with 3 additions and 3 deletions
|
@ -20,9 +20,9 @@ type getVersionJSONRequest struct {
|
||||||
RecheckNow bool `json:"recheck_now"`
|
RecheckNow bool `json:"recheck_now"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// temoraryError is the interface for temporary errors from the Go standard
|
// temporaryError is the interface for temporary errors from the Go standard
|
||||||
// library.
|
// library.
|
||||||
type temoraryError interface {
|
type temporaryError interface {
|
||||||
error
|
error
|
||||||
Temporary() (ok bool)
|
Temporary() (ok bool)
|
||||||
}
|
}
|
||||||
|
@ -57,7 +57,7 @@ func handleGetVersionJSON(w http.ResponseWriter, r *http.Request) {
|
||||||
}()
|
}()
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
var terr temoraryError
|
var terr temporaryError
|
||||||
if errors.As(err, &terr) && terr.Temporary() {
|
if errors.As(err, &terr) && terr.Temporary() {
|
||||||
// Temporary network error. This case may happen while
|
// Temporary network error. This case may happen while
|
||||||
// we're restarting our DNS server. Log and sleep for
|
// we're restarting our DNS server. Log and sleep for
|
||||||
|
|
Loading…
Reference in a new issue