refactor(decrypt): remove unused decryptFromUuid/decryptFromData#112
Open
dobby-coder[bot] wants to merge 1 commit into
Open
refactor(decrypt): remove unused decryptFromUuid/decryptFromData#112dobby-coder[bot] wants to merge 1 commit into
dobby-coder[bot] wants to merge 1 commit into
Conversation
These two exported functions were never re-exported from src/index.ts and never referenced in src/ or tests/. Sealed/Opened call the lower-level helpers (inspectSealed, resolveRecipientKey, resolveUSK, unsealAndCollect) directly instead. Remove both functions and their DecryptFromUuidOptions/ DecryptFromDataOptions interfaces, the stale "Legacy top-level functions" section comment, and the imports that become unused (DecryptFileResult, DecryptDataResult, extractAllZipEntries, triggerBrowserDownloads, parseSender). The two remaining section comments no longer mention the removed "legacy functions". Closes #105 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
Author
There was a problem hiding this comment.
VERDICT: approve
Reviewed refactor(decrypt) — clean dead-code removal, no findings (cycle 1).
Verification:
- No references to decryptFromUuid / decryptFromData / their option interfaces remain in src/ or tests/ (grep clean); neither was re-exported from src/index.ts.
- Dropped imports (DecryptFileResult, DecryptDataResult, extractAllZipEntries, triggerBrowserDownloads, parseSender) are all unused after removal; kept imports (SenderIdentity, SessionCallback, downloadFileWithRetry) are still referenced.
- npm run typecheck: clean. npm test: 205/205 passing.
Rule check:
- Conventional-commit title: pr-title.yml present, "refactor(decrypt): ..." is valid.
- closingIssuesReferences correctly lists #105 (this is the complete fix, so auto-close is intended).
- No regression test required — pure removal of dead, untested, unexported code.
- Writing-rules: PR body is clean.
Review Dobby 2 handed over 0 findings. Signing off.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #105
What
src/crypto/decrypt.tsexported two functions that were never re-exported fromsrc/index.tsand never referenced insrc/ortests/.Sealed/Openedcall the lower-level helpers (inspectSealed,resolveRecipientKey,resolveUSK,unsealAndCollect) directly.decryptFromUuid,decryptFromDataand theirDecryptFromUuidOptions/DecryptFromDataOptionsinterfaces.Legacy top-level functionssection comment.DecryptFileResult,DecryptDataResult(types),extractAllZipEntries,triggerBrowserDownloads,parseSender. Helpers still used elsewhere (downloadFileWithRetry,SenderIdentity,SessionCallback, ...) are kept.--- Inspect ---/--- Unseal helpers ---section comments so they no longer refer to the removed "legacy functions".Verification
npm run typecheck— cleannpm test— 205/205 passingNet diff: 1 file, +3 / -79.