[PR #5305] [MERGED] fix: SmartEnvInput environment context bug #5154

Closed
opened 2026-03-17 02:37:40 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hoppscotch/hoppscotch/pull/5305
Author: @nivedin
Created: 8/4/2025
Status: Merged
Merged: 8/5/2025
Merged by: @jamesgeorge007

Base: patchHead: fix/env-input-env-bug


📝 Commits (2)

  • eab2c84 fix: env input variable undefined bug
  • 74bdd4f chore: code refactor

📊 Changes

2 files changed (+2 additions, -2 deletions)

View changed files

📝 packages/hoppscotch-common/src/components/http/RequestTab.vue (+1 -1)
📝 packages/hoppscotch-common/src/components/smart/EnvInput.vue (+1 -1)

📄 Description

Closes #5304

This PR fixes an issue in SmartEnvInput where the environment variables were not being populated in the context. The root cause was that the RequestOption component was not correctly propagating the env prop.

With this fix, we now check if the env array is empty and populate envVars accordingly to ensure the expected environment context is applied.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hoppscotch/hoppscotch/pull/5305 **Author:** [@nivedin](https://github.com/nivedin) **Created:** 8/4/2025 **Status:** ✅ Merged **Merged:** 8/5/2025 **Merged by:** [@jamesgeorge007](https://github.com/jamesgeorge007) **Base:** `patch` ← **Head:** `fix/env-input-env-bug` --- ### 📝 Commits (2) - [`eab2c84`](https://github.com/hoppscotch/hoppscotch/commit/eab2c844db118edecc0ad1d4637dfe8cf9f6f830) fix: env input variable undefined bug - [`74bdd4f`](https://github.com/hoppscotch/hoppscotch/commit/74bdd4f4c73e40402222ad7d3adf8792b9fbca97) chore: code refactor ### 📊 Changes **2 files changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `packages/hoppscotch-common/src/components/http/RequestTab.vue` (+1 -1) 📝 `packages/hoppscotch-common/src/components/smart/EnvInput.vue` (+1 -1) </details> ### 📄 Description Closes #5304 This PR fixes an issue in `SmartEnvInput` where the environment variables were not being populated in the context. The root cause was that the `RequestOption` component was not correctly propagating the env prop. With this fix, we now check if the `env` array is empty and populate `envVars` accordingly to ensure the expected environment context is applied. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-17 02:37:40 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#5154
No description provided.