mirror of https://github.com/Xhofe/alist
				
				
				
			fix(aliyundrive): return error if got wrong http code (#2543)
							parent
							
								
									18a63e34dd
								
							
						
					
					
						commit
						9c1ffdbb82
					
				| 
						 | 
				
			
			@ -62,6 +62,8 @@ func (d *AliDrive) request(url, method string, callback base.ReqCallback, resp i
 | 
			
		|||
			return d.request(url, method, callback, resp)
 | 
			
		||||
		}
 | 
			
		||||
		return nil, errors.New(e.Message), e
 | 
			
		||||
	} else if res.IsError() {
 | 
			
		||||
		return nil, errors.New("bad status code " + res.Status()), e
 | 
			
		||||
	}
 | 
			
		||||
	return res.Body(), nil, e
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue