mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2025-12-20 19:16:35 +08:00
请求源站错误时增加503、504错误
This commit is contained in:
@@ -109,7 +109,7 @@ func (this *HTTPRequest) doRoot() (isBreak bool) {
|
||||
}
|
||||
return
|
||||
} else {
|
||||
this.write500(err)
|
||||
this.write50x(err, http.StatusInternalServerError)
|
||||
logs.Error(err)
|
||||
return true
|
||||
}
|
||||
@@ -138,7 +138,7 @@ func (this *HTTPRequest) doRoot() (isBreak bool) {
|
||||
}
|
||||
return
|
||||
} else {
|
||||
this.write500(err)
|
||||
this.write50x(err, http.StatusInternalServerError)
|
||||
logs.Error(err)
|
||||
return true
|
||||
}
|
||||
@@ -283,8 +283,7 @@ func (this *HTTPRequest) doRoot() (isBreak bool) {
|
||||
|
||||
reader, err := os.OpenFile(filePath, os.O_RDONLY, 0444)
|
||||
if err != nil {
|
||||
this.write500(err)
|
||||
logs.Error(err)
|
||||
this.write50x(err, http.StatusInternalServerError)
|
||||
return true
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user