Skip to content

Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia

fix: update masked secret environment value after replace action (#5335)

Nivedin24c0f9370b3f
diff --git a/packages/hoppscotch-common/src/components/smart/EnvInput.vue b/packages/hoppscotch-common/src/components/smart/EnvInput.vue
index 748baae8a..8c9643fb3 100644
--- a/packages/hoppscotch-common/src/components/smart/EnvInput.vue
+++ b/packages/hoppscotch-common/src/components/smart/EnvInput.vue
@@ -177,6 +177,19 @@ watch(
}
)
+//update secretText when modelValue changes
+watch(
+ () => props.modelValue,
+ (newVal) => {
+ if (secretText.value !== newVal) {
+ secretText.value = newVal
+ }
+ },
+ {
+ immediate: true,
+ }
+)
+
onClickOutside(autoCompleteWrapper, () => {
showSuggestionPopover.value = false
})