mirror of https://github.com/halo-dev/halo
				
				
				
			refactor: optimize axios interceptor text/html content type detection (#7142)
#### What type of PR is this? /area ui /kind improvement /milestone 2.20.x #### What this PR does / why we need it: Optimize axios interceptor text/html content type detection <img width="1461" alt="image" src="https://github.com/user-attachments/assets/6bb59a1d-81cc-4ea2-ac61-17e30eab4281" /> #### Does this PR introduce a user-facing change? ```release-note None ```pull/7149/head
							parent
							
								
									f9ddeebb1f
								
							
						
					
					
						commit
						8f39266c8c
					
				| 
						 | 
				
			
			@ -72,7 +72,7 @@ export function setupApiClient() {
 | 
			
		|||
 | 
			
		||||
      const contentType = error.response?.headers["content-type"];
 | 
			
		||||
 | 
			
		||||
      if (contentType === "text/html") {
 | 
			
		||||
      if (contentType.toLowerCase().includes("text/html")) {
 | 
			
		||||
        createHTMLContentModal({
 | 
			
		||||
          uniqueId: objectHash(error.response?.data || ""),
 | 
			
		||||
          title: error.response?.status.toString(),
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue