mirror of
				https://github.com/9001/copyparty.git
				synced 2025-10-31 04:32:20 -06:00 
			
		
		
		
	xhrchk: generic error only as fallback
This commit is contained in:
		
							parent
							
								
									1bcdf8c9e3
								
							
						
					
					
						commit
						0453b7ac53
					
				|  | @ -2298,9 +2298,6 @@ function xhrchk(xhr, prefix, e404, lvl, tag) { | |||
|     if (xhr.status == 404) | ||||
|         return toast.err(0, prefix + e404 + suf, tag); | ||||
| 
 | ||||
|     if (XC_CMSG[xhr.status]) | ||||
|         errtxt = XC_CMSG[xhr.status]; | ||||
| 
 | ||||
|     if (!xhr.status && !errtxt) | ||||
|         return toast.err(0, prefix + L.xhr0); | ||||
| 
 | ||||
|  | @ -2319,5 +2316,8 @@ function xhrchk(xhr, prefix, e404, lvl, tag) { | |||
|         document.body.appendChild(fr); | ||||
|     } | ||||
| 
 | ||||
|     if (XC_CMSG[xhr.status] && (errtxt.indexOf('<html') + 1)) | ||||
|         errtxt = XC_CMSG[xhr.status]; | ||||
| 
 | ||||
|     return fun(0, prefix + xhr.status + ": " + errtxt, tag); | ||||
| } | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue