mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-26 01:06:00 +03:00
[PR #5814] [MERGED] fix(common): handle null request ref in InspectionService for test-runner tabs #5362
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#5362
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/hoppscotch/hoppscotch/pull/5814
Author: @Leon-Luu
Created: 1/29/2026
Status: ✅ Merged
Merged: 1/29/2026
Merged by: @jamesgeorge007
Base:
main← Head:fix/issue_5813_pre_hook_error📝 Commits (3)
aab2d61fix: handle null request in inspection service for test-runner tabs3969d60fix: copilot suggestion with debouncedReq asce4c587refactor: simplify null guard and type assertion📊 Changes
1 file changed (+11 additions, -4 deletions)
View changed files
📝
packages/hoppscotch-common/src/services/inspection/index.ts(+11 -4)📄 Description
Add a null guard before calling getInspections() to:
This null value propagates to debouncedReq, which is then passed to getInspections(), causing a type mismatch.
Closes #
https://github.com/hoppscotch/hoppscotch/issues/5813
What's changed
Notes to reviewers
Summary by cubic
Skip inspection when the request is null to prevent pre-hook errors in test‑runner tabs. Adds a null guard in InspectionService and a type assertion to satisfy TypeScript, avoiding getInspections() calls with a null request.
Written for commit
ce4c587b70. Summary will update on new commits.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.