Task Summary
download.service.ts carries a top-level var contentDisposition = require("content-disposition") that is never read or called anywhere in the file or in the rest of frontend/src. The dependency itself is therefore dead — drop it along with its @types/content-disposition companion, and clean up the bundled-license roll-up for the transitive packages that fall out with it.
| Probe |
Result |
grep -rn 'contentDisposition' frontend/src |
1 hit — the require line itself; no read sites |
grep -rn 'content-disposition' frontend/src |
1 hit — same line |
Runtime use of contentDisposition |
none |
Compile use of @types/content-disposition |
none (the require returns any since it's CommonJS) |
Before → After (download.service.ts):
┌──────────────────────────────────────────────────────────────────┐
│ ...imports... │
│ │
│ var contentDisposition = require("content-disposition"); ← dead │
│ │
│ export const EXPORT_BASE_URL = ... │
└──────────────────────────────────────────────────────────────────┘
↓
┌──────────────────────────────────────────────────────────────────┐
│ ...imports... │
│ │
│ export const EXPORT_BASE_URL = ... │
└──────────────────────────────────────────────────────────────────┘
Concrete edits:
| File |
Change |
frontend/src/app/dashboard/service/user/download/download.service.ts |
drop the dead require line |
frontend/package.json |
remove content-disposition (deps) and @types/content-disposition (devDeps) |
frontend/LICENSE-binary |
drop content-disposition@0.5.4 plus the 5 transitives no longer bundled (base64-js, buffer, ieee754, path-browserify, safe-buffer) |
frontend/yarn.lock |
regenerate so transitive entries fall away |
Task Type
Task Summary
download.service.tscarries a top-levelvar contentDisposition = require("content-disposition")that is never read or called anywhere in the file or in the rest offrontend/src. The dependency itself is therefore dead — drop it along with its@types/content-dispositioncompanion, and clean up the bundled-license roll-up for the transitive packages that fall out with it.grep -rn 'contentDisposition' frontend/srcrequireline itself; no read sitesgrep -rn 'content-disposition' frontend/srccontentDisposition@types/content-dispositionrequirereturnsanysince it's CommonJS)Before → After (
download.service.ts):Concrete edits:
frontend/src/app/dashboard/service/user/download/download.service.tsrequirelinefrontend/package.jsoncontent-disposition(deps) and@types/content-disposition(devDeps)frontend/LICENSE-binarycontent-disposition@0.5.4plus the 5 transitives no longer bundled (base64-js,buffer,ieee754,path-browserify,safe-buffer)frontend/yarn.lockTask Type