mirror of
				https://github.com/strapi/strapi.git
				synced 2025-10-31 09:56:44 +00:00 
			
		
		
		
	Clear db formats on replace
Signed-off-by: Alexandre Bodin <bodin.alex@gmail.com>
This commit is contained in:
		
							parent
							
								
									6cdf0a7891
								
							
						
					
					
						commit
						5de985d724
					
				| @ -197,6 +197,9 @@ module.exports = { | ||||
| 
 | ||||
|     await strapi.plugins.upload.provider.upload(fileData); | ||||
| 
 | ||||
|     // clear old formats
 | ||||
|     _.set(fileData, 'formats', {}); | ||||
| 
 | ||||
|     const thumbnailFile = await generateThumbnail(fileData); | ||||
|     if (thumbnailFile) { | ||||
|       await strapi.plugins.upload.provider.upload(thumbnailFile); | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Alexandre Bodin
						Alexandre Bodin