[PR #2664] [MERGED] fix: allow posting empty key files in multipart/form-data #3973

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

📋 Pull Request Information

Original PR: https://github.com/hoppscotch/hoppscotch/pull/2664
Author: @fumblehool
Created: 9/14/2022
Status: Merged
Merged: 10/6/2022
Merged by: @AndrewBastin

Base: mainHead: fumblehoolfix/issue-2293


📝 Commits (1)

  • b850156 fix: #2293 : post a file using multipart/form-data

📊 Changes

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

View changed files

📝 packages/hoppscotch-app/src/components/http/BodyParameters.vue (+2 -2)
📝 packages/hoppscotch-app/src/helpers/utils/EffectiveURL.ts (+1 -1)

📄 Description

Description

form-data param have following properties -

{
    active: boolean,
    key: string,
    value: string,
    isFile: boolean,
    value: array
}

There was a check to remove blank parameter. This check is based on key.
However, in case of file upload - key is empty but isFile is set to True.

This PR updates those checks.


🔄 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/2664 **Author:** [@fumblehool](https://github.com/fumblehool) **Created:** 9/14/2022 **Status:** ✅ Merged **Merged:** 10/6/2022 **Merged by:** [@AndrewBastin](https://github.com/AndrewBastin) **Base:** `main` ← **Head:** `fumblehoolfix/issue-2293` --- ### 📝 Commits (1) - [`b850156`](https://github.com/hoppscotch/hoppscotch/commit/b850156c86be61e808e5b6d1d657760e24cf9adb) fix: #2293 : post a file using multipart/form-data ### 📊 Changes **2 files changed** (+3 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `packages/hoppscotch-app/src/components/http/BodyParameters.vue` (+2 -2) 📝 `packages/hoppscotch-app/src/helpers/utils/EffectiveURL.ts` (+1 -1) </details> ### 📄 Description ### Description `form-data` param have following properties - ``` { active: boolean, key: string, value: string, isFile: boolean, value: array } ``` There was a check to remove blank parameter. This check is based on `key`. However, in case of file upload - `key` is empty but `isFile` is set to True. This PR updates those checks. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-17 01:32:37 +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#3973
No description provided.