feat: missing files from last commit
This commit is contained in:
@@ -120,7 +120,7 @@ import IconTrash2 from "~icons/lucide/trash-2"
|
|||||||
import IconDone from "~icons/lucide/check"
|
import IconDone from "~icons/lucide/check"
|
||||||
import IconPlus from "~icons/lucide/plus"
|
import IconPlus from "~icons/lucide/plus"
|
||||||
import IconTrash from "~icons/lucide/trash"
|
import IconTrash from "~icons/lucide/trash"
|
||||||
import IconLock from "~icons/lucide/lock"
|
import IconLock from "~icons/lucide/lock"
|
||||||
import { clone } from "lodash-es"
|
import { clone } from "lodash-es"
|
||||||
import { computed, ref, watch } from "vue"
|
import { computed, ref, watch } from "vue"
|
||||||
import * as E from "fp-ts/Either"
|
import * as E from "fp-ts/Either"
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ import IconTrash from "~icons/lucide/trash"
|
|||||||
import IconTrash2 from "~icons/lucide/trash-2"
|
import IconTrash2 from "~icons/lucide/trash-2"
|
||||||
import IconDone from "~icons/lucide/check"
|
import IconDone from "~icons/lucide/check"
|
||||||
import IconPlus from "~icons/lucide/plus"
|
import IconPlus from "~icons/lucide/plus"
|
||||||
import IconLock from "~icons/lucide/lock"
|
import IconLock from "~icons/lucide/lock"
|
||||||
import { platform } from "~/platform"
|
import { platform } from "~/platform"
|
||||||
|
|
||||||
type EnvironmentVariable = {
|
type EnvironmentVariable = {
|
||||||
|
|||||||
@@ -87,28 +87,32 @@ export const execPreRequestScript = (
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
const envSetHandle = vm.newFunction("set", (keyHandle, valueHandle) => {
|
const envSetHandle = vm.newFunction(
|
||||||
const key: unknown = vm.dump(keyHandle)
|
"set",
|
||||||
const value: unknown = vm.dump(valueHandle)
|
(keyHandle, valueHandle, secretHandle) => {
|
||||||
|
const key: unknown = vm.dump(keyHandle)
|
||||||
|
const value: unknown = vm.dump(valueHandle)
|
||||||
|
const secret: boolean = vm.dump(secretHandle)
|
||||||
|
|
||||||
|
if (typeof key !== "string") {
|
||||||
|
return {
|
||||||
|
error: vm.newString("Expected key to be a string"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (typeof value !== "string") {
|
||||||
|
return {
|
||||||
|
error: vm.newString("Expected value to be a string"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
currentEnvs = setEnv(key, value, secret, currentEnvs)
|
||||||
|
|
||||||
if (typeof key !== "string") {
|
|
||||||
return {
|
return {
|
||||||
error: vm.newString("Expected key to be a string"),
|
value: vm.undefined,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
)
|
||||||
if (typeof value !== "string") {
|
|
||||||
return {
|
|
||||||
error: vm.newString("Expected value to be a string"),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
currentEnvs = setEnv(key, value, currentEnvs)
|
|
||||||
|
|
||||||
return {
|
|
||||||
value: vm.undefined,
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
const envResolveHandle = vm.newFunction("resolve", (valueHandle) => {
|
const envResolveHandle = vm.newFunction("resolve", (valueHandle) => {
|
||||||
const value: unknown = vm.dump(valueHandle)
|
const value: unknown = vm.dump(valueHandle)
|
||||||
|
|||||||
@@ -527,28 +527,32 @@ export const execTestScript = (
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
const envSetHandle = vm.newFunction("set", (keyHandle, valueHandle) => {
|
const envSetHandle = vm.newFunction(
|
||||||
const key: unknown = vm.dump(keyHandle)
|
"set",
|
||||||
const value: unknown = vm.dump(valueHandle)
|
(keyHandle, valueHandle, secretHandle) => {
|
||||||
|
const key: unknown = vm.dump(keyHandle)
|
||||||
|
const value: unknown = vm.dump(valueHandle)
|
||||||
|
const secret: boolean = vm.dump(secretHandle)
|
||||||
|
|
||||||
|
if (typeof key !== "string") {
|
||||||
|
return {
|
||||||
|
error: vm.newString("Expected key to be a string"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (typeof value !== "string") {
|
||||||
|
return {
|
||||||
|
error: vm.newString("Expected value to be a string"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
currentEnvs = setEnv(key, value, secret, currentEnvs)
|
||||||
|
|
||||||
if (typeof key !== "string") {
|
|
||||||
return {
|
return {
|
||||||
error: vm.newString("Expected key to be a string"),
|
value: vm.undefined,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
)
|
||||||
if (typeof value !== "string") {
|
|
||||||
return {
|
|
||||||
error: vm.newString("Expected value to be a string"),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
currentEnvs = setEnv(key, value, currentEnvs)
|
|
||||||
|
|
||||||
return {
|
|
||||||
value: vm.undefined,
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
const envResolveHandle = vm.newFunction("resolve", (valueHandle) => {
|
const envResolveHandle = vm.newFunction("resolve", (valueHandle) => {
|
||||||
const value: unknown = vm.dump(valueHandle)
|
const value: unknown = vm.dump(valueHandle)
|
||||||
|
|||||||
Reference in New Issue
Block a user