From 459e88784af0a222e8444ae3aa83c9322f9a18f9 Mon Sep 17 00:00:00 2001 From: arunshenoy99 Date: Fri, 27 Dec 2024 17:23:18 +0530 Subject: [PATCH] Auto enable all settings when image optimization is turned on --- components/imageOptimizationSettings/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/imageOptimizationSettings/index.js b/components/imageOptimizationSettings/index.js index b34efc8..df44fbb 100644 --- a/components/imageOptimizationSettings/index.js +++ b/components/imageOptimizationSettings/index.js @@ -62,6 +62,8 @@ const ImageOptimizationSettings = ( { methods } ) => { case 'enabled': updatedSettings.enabled = value; updatedSettings.auto_optimized_uploaded_images.enabled = value; + updatedSettings.auto_optimized_uploaded_images.auto_delete_original_image = + value; updatedSettings.bulk_optimization = value; updatedSettings.lazy_loading.enabled = value; updatedSettings.prefer_optimized_image_when_exists = value;