Commit 738e22e3 authored by JessonChan's avatar JessonChan Committed by astaxie

zero timeout means wait until resp

parent 69fc22f0
......@@ -65,14 +65,8 @@ func createDefaultCookie() {
// Overwrite default settings
func SetDefaultSetting(setting BeegoHttpSettings) {
settingMutex.Lock()
defer settingMutex.Unlock()
defaultSetting = setting
if defaultSetting.ConnectTimeout == 0 {
defaultSetting.ConnectTimeout = 60 * time.Second
}
if defaultSetting.ReadWriteTimeout == 0 {
defaultSetting.ReadWriteTimeout = 60 * time.Second
}
settingMutex.Unlock()
}
// return *BeegoHttpRequest with specific method
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment