mirror of
				https://github.com/SillyTavern/SillyTavern.git
				synced 2025-06-05 21:59:27 +02:00 
			
		
		
		
	Fix Chub import by URL
This commit is contained in:
		@@ -4024,7 +4024,7 @@ async function downloadChubCharacter(id) {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    const buffer = await result.buffer();
 | 
			
		||||
    const fileName = result.headers.get('content-disposition').split('filename=')[1];
 | 
			
		||||
    const fileName = result.headers.get('content-disposition')?.split('filename=')[1] || `${sanitize(id)}.png`;
 | 
			
		||||
    const fileType = result.headers.get('content-type');
 | 
			
		||||
 | 
			
		||||
    return { buffer, fileName, fileType };
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user