[Question] Env var precedence #268
Unanswered
kobenguyent
asked this question in
Q&A
Replies: 1 comment
-
Restfox has a defined order: Restfox resolves environment variables from top to bottom. So you can use a workspace env var inside a folder env var. Workspace env:
Folder env:
Resolved Request Env:
Postman's behavior seems incorrect, as immediate parent should take precedence. I'll explain in code let a = 10 // workspace env
{ // folder env
a = 20
{ // sub folder env
a = 30
{
console.log(a) // a should be 30 and not 10
}
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
So I have a postman collection which has env vars set at collection, for instance
email
is123@hello.com
, it is calledVariables
when opening the Collection panelNow when I choose an Environment from the Environment list, this Environment is also set the
email
is345@hello.com
.When calling a request which invoking this
email
345@hello.com
123@hello.com
And the question is, what shall be the higher precedence
Beta Was this translation helpful? Give feedback.
All reactions