diff --git a/frontend/src/common/util/parameterTranslation.ts b/frontend/src/common/util/parameterTranslation.ts index 5f3c9294dd..2d010b3815 100644 --- a/frontend/src/common/util/parameterTranslation.ts +++ b/frontend/src/common/util/parameterTranslation.ts @@ -138,9 +138,7 @@ export const frontendToBackendParameters = ( generationParameters.init_img = imageToProcessUrl; generationParameters.strength = img2imgStrength; - if (shouldPreserveMaskedArea) { - generationParameters.invert_mask = true; - } + generationParameters.invert_mask = shouldPreserveMaskedArea; if (shouldUseInpaintReplace) { generationParameters.inpaint_replace = inpaintReplace;