diff --git a/python_src/SAR_MultiSlc.py b/python_src/SAR_MultiSlc.py
index e48f8d01b93080431dc23aa2bfa7a5dd52b560c3..33f309f3250eac90ad0bf08972f131a0ae897f79 100644
--- a/python_src/SAR_MultiSlc.py
+++ b/python_src/SAR_MultiSlc.py
@@ -544,7 +544,7 @@ if __name__ == "__main__":
             func_utils.silentremove(output_dir, interf_roi)
 
 
-        if light_version == "yes":
+        if light_version is True:
             func_utils.log(logging.INFO, "\n Removing files for light version \n")
             func_utils.silentremove(output_dir, dop_file)
             func_utils.silentremove(output_dir, demProj_Slave)
@@ -559,7 +559,7 @@ if __name__ == "__main__":
             func_utils.silentremove(output_dir, i_file)
 
 
-    if light_version == "yes":
+    if light_version is True:
         func_utils.log(logging.INFO, "\n Removing files for light version \n")
         if os.path.exists(os.path.join(master_data_dir, dop_file)):
             func_utils.silentremove(master_data_dir, dop_file)
diff --git a/python_src/SAR_MultiSlc_IW.py b/python_src/SAR_MultiSlc_IW.py
index be0162128a4aed13336dfbb334d1cfc1c659cf2f..ef8c738c4fb050edfe7be43567291094ac9c98a8 100644
--- a/python_src/SAR_MultiSlc_IW.py
+++ b/python_src/SAR_MultiSlc_IW.py
@@ -372,7 +372,7 @@ if __name__ == "__main__":
 
 
             # Master deramp
-            if light_version == "no":
+            if light_version is not True:
                 masterDeramp = os.path.splitext(master_Image_base)[0]+"_deramp.tif"
                 Con_masterDeramp = os.path.join(master_data_dir, masterDeramp)
                 diapOTBApp.concatenate(Deramp_BurstToConcatenateM, master_Image, firstBurst, Con_masterDeramp)
@@ -393,7 +393,7 @@ if __name__ == "__main__":
 
         # ###### Concatenating and georeferencing bursts ###### #
         # Slave Deramp
-        if light_version == "no":
+        if light_version is not True:
             Con_slaveDeramp = os.path.splitext(master_Image_base)[0] + "_deramp.tif"
             diapOTBApp.concatenate(Deramp_BurstToConcatenateS, slave_Image, firstBurst, Con_slaveDeramp)