rbac-client doesn't work with an object as a param
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 48/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- typescript
- Domain
- api
Research direction
Start by tracing the TypeScript getWorkspace entry point and how its arguments are converted into the request URL. Reproduce both the inline-argument and params-object calls, then verify that the object form produces the same workspace URL without [object Object].
Written by the indexing model from the issue text.
Description
When using rbac-client, if we send a getWorkspace request using inline arguments:
const workspaceId = `foo-bar-baz`
getWorkspace(workspaceId, true, {})
we get a properly formed URL:
/api/rbac/v2/workspaces/foo-bar-baz/
If we send a request using a params object - which is the style we'd like to use, so to avoid passing optional args to the call - like so:
const workspaceId = `foo-bar-baz`
getWorkspace({ id: workspaceId })
we get a malformed URL:
/api/rbac/v2/workspaces/[object Object]
- Dominant language
- TypeScript
- Stars
- 7
- Forks
- 37
- Avg merge
- 6d 31m
- Merged PRs (30d)
- 19
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from RedHatInsights/javascript-clients
-
Difficulty 3/5 1-2 days Newbie friendliness 48/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
RedHatInsights/javascript-clients#369 · 2 comments ·
-
axios security issue Open
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 4/5 3-5 days Newbie friendliness 30/100
RedHatInsights/javascript-clients#166 · 3 comments ·
All issues in RedHatInsights/javascript-clients
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
copse-dev/agent-pane#2953 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·