refactor(actions): reduce remaining axios usage in document service
This commit is contained in:
@@ -1958,3 +1958,36 @@ Validation:
|
||||
Follow-ups:
|
||||
|
||||
- Optional next bounded slice: assess whether a dedicated signed-request client helper should encapsulate hash + headers + method conventions to prevent future drift in remaining signed flows.
|
||||
|
||||
---
|
||||
|
||||
### CL-055: TASK22260 next slice — document direct service signed/delete axios reduction
|
||||
|
||||
date: 2026-03-25
|
||||
author: Cline
|
||||
scope: `actions/services/documentDirectService.js`
|
||||
type: change
|
||||
rationale: Execute next bounded risk-reduction slice by migrating remaining non-download document-service delete and signed-get helper calls away from direct axios response extraction to shared endpoint clients.
|
||||
impact: Further reduces duplicated axios boilerplate and aligns document service internals with shared request-client conventions while preserving existing hash/query and catch-path behavior.
|
||||
status: completed
|
||||
|
||||
Summary:
|
||||
|
||||
- Migrated signed hashed delete-helper flows from direct `axios({...}).then(res.data)` to `requestJson({...})`:
|
||||
- `deleteAwaitingSubmissionsFromBlob`
|
||||
- `deleteMyRepresentationsFromBlob`
|
||||
- Migrated delete helper GET calls from `axios.get(...).then(res.data)` to `getJson(...)`:
|
||||
- `deleteBlob`
|
||||
- `deleteRepBlob`
|
||||
- Preserved behavior contracts:
|
||||
- unchanged query/hash composition and endpoint URLs
|
||||
- unchanged catch-path logging with `consoleLogger`
|
||||
- Left `downloadBlob` unchanged in this slice (special-case behavior path retained for separate focused handling).
|
||||
|
||||
Validation:
|
||||
|
||||
- `npm run lint` -> warnings only (pre-existing `react-hooks/exhaustive-deps`; no new lint errors)
|
||||
|
||||
Follow-ups:
|
||||
|
||||
- Optional next bounded slice: isolate and correct `downloadBlob` behavior in `documentDirectService` (including legacy `res` usage) behind an explicit, tested contract.
|
||||
|
||||
Reference in New Issue
Block a user