fix: postman env variables are to be imported as secrets (#4474)

Co-authored-by: Shoban <mshobanr@ford.com>
Co-authored-by: jamesgeorge007 <25279263+jamesgeorge007@users.noreply.github.com>
This commit is contained in:
shobanrajm
2024-10-28 16:58:12 +05:30
committed by GitHub
parent 3722be0de1
commit 84f0f478d4
5 changed files with 53 additions and 12 deletions

View File

@@ -311,10 +311,13 @@ watch(
env: {
key: e.key,
value: e.secret
? (secretEnvironmentService.getSecretEnvironmentVariable(
? secretEnvironmentService.getSecretEnvironmentVariable(
editingID.value ?? "",
index
)?.value ?? "")
)?.value ??
// @ts-expect-error `value` field can exist for secret environment variables as inferred while importing
e.value ??
""
: e.value,
secret: e.secret,
},
@@ -352,10 +355,6 @@ const removeEnvironmentVariable = (id: number) => {
const isLoading = ref(false)
const saveEnvironment = async () => {
if (isLoading.value) {
return
}
isLoading.value = true
if (!editingName.value) {