Public report of solarizeddev/firedown, published 17 November 2026. It has the same score, grades and number of findings as the full report. The details of security findings (where they are in the code, which known vulnerabilities and which passwords or keys were found) are left out, so nobody can use them against the project.
Public
Executive report Measured under the Code Assurance Index, an open standard for code quality, using its published scoring rules (rubric version 2026.11.4). Assert signed this survey and filed it in the standard's public register, where anyone can look it up by its survey ID. Check this survey → Signed and filed in the standard's public register, 17 November 2026, 04:41 UTC · Survey ID cd_4af66539cc3e443eb241d6117e05168b

solarizeddev/firedown

Measured 17 November 2026, 04:41 UTC, at code version 3dfb0f5

First survey, so nothing to compare with yet
CAI score 28.8out of 100 Weak
CriticalWeakAdequateStrongExemplary

The score is built from these lenses. Each lens grades one area of the code, such as how easy it is to change or how well it is protected. The weakest lens counts most, so one weak area pulls the score down instead of being averaged away.

A large codebase: 164,866 lines of product code in 3 projects, tests not counted · Estimated rebuild effort: about 1.0 person-years · Weakest lens: Production Readiness, 15.0

Findings by how serious they are

33 critical 1410 serious 116 minor

14 dimensions are left out of the score. For each one, we either couldn't measure it in this code, or found no evidence of the safeguard we look for, such as a tested backup restore. They count neither for nor against the score, and Limitations lists each one with its reason.

This survey was produced by

Assert small markCanine Code Analyzer
Producer
Canine Development
Analyzer
Canine Code Analyzer engine 1.0.0
Measured
17 November 2026, 04:41 UTC

A measurement, not a certificate. The Code Assurance Index records a number together with the evidence it was worked out from, so anyone can recalculate it, but it doesn't certify or guarantee the code. The standard was written by Canine Development, which also builds the Canine Code Analyzer. It is open to any tool that implements it, and today the Canine Code Analyzer is the only one that does.

The score is deterministic, which means the same code always gets the same score. We work it out with tools that follow published rules, and an AI model never decides it, so anyone who applies the same rules to the same code gets the same number. How it is done is explained under Methodology ▸

65of 65 dimensions measured by tools.
1549of 1559 findings point to an exact file and line, so you can open each one in the code. The other 10 concern the repository as a whole, such as missing documentation.
65dimensions across 7 lenses, read from 164,866 lines of product code in 3 projects.
Chapters

Executive summary

solarizeddev/firedown falls short of our standard for production because five passwords or keys sit in the current code and we found no working pipeline that builds or tests changes to the code. It scores 28.8 out of 100 and is rated Weak, and 15 of its 33 critical findings are security problems.

Production Readiness, at 15.0, is the weakest lens and counts most in the score. The best first step is replacing the five exposed passwords or keys and switching the old ones off, worth about 11.7 points. Adding text alternatives comes next, worth about 3.7 points. Raising Production Readiness to 70 would lift the score to about 40.7.

Six weaknesses in the code could be used by an attacker. Five passwords or keys in the code and one in the code's history are open to anyone who can read the repository, and seven form fields can't be read by a screen reader. Fixing the weaknesses the scanner points to, replacing each exposed password or key and labelling the form fields would close these risks. The three places where the code runs text as code or as a command need a direct call instead. The four pages that don't say their language need their language set.

The product code is 164,866 lines, about €150,000 to rebuild.

A lens is capped at Adequate while one of its dimensions scores below 4 out of 10, however well the rest of the lens does. That way a serious problem in one place always shows in the lens's rating.

How the score is built: what each lens counts for The lenses don't count equally. The weakest lens counts most, the next weakest a little less, and so on, so a weak area pulls the score down instead of being averaged away. In the bar below, each part's width shows how much that lens counts and its colour shows its rating. Improving the widest part moves the score most, and as that lens improves, it counts for less, because another lens becomes the weakest.
Production Readiness 15.0 · counts for 46%Accessibility 27.5 · counts for 25%Code Health 42.0 · counts for 14%Maturity 54.0 · counts for 8%Performance 60.0 · counts for 4%Security and Compliance 72.8 · counts for 2%Architecture 76.3 · counts for 1%

If Production Readiness rose from 15.0 to 70, the lowest score rated Strong, the score would rise from 28.8 to about 40.7.

Code composition: what the lines of code are
Product code 93%Tests 7%
Rebuild cost: about €150,000 · Estimate
Cost to rebuild€50,000 to €250,000, for 831 to 2,637 hours of work, about 1.0 person-years for 1 to 2 engineers
Difficulty of the problemStandard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write.
Quality factor×0.7 at a score of 29. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it.
SizeLarge: 164,866 lines of product code
What it is notNot a quotation: nobody has offered to build it for that. Not a valuation: it says nothing about what the business is worth. Not a certified figure: no professional has signed it as one.

How the estimate is made: We price the hours a team would need to write this code again, at €60 to €95 an hour. Declarations and boilerplate are priced at a fast rate and logic at a slower one, and the logic is then multiplied by the difficulty of the problem and by the quality factor. The estimate can be about 30% off either way, and it moves most with the hourly rate and the difficulty. For this code, every line is priced as straight logic, which keeps the estimate on the low side.

Top priorities

The three actions that raise the score most for the work they take. The full ranked list is in the Roadmap.

1
Resolve the 5 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED.
Raises the score by about 11.7 points · Low effort · REDACTED Scanning
2
Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
Raises the score by about 3.7 points · Medium effort · Text alternatives
3
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
Raises the score by about 3.7 points · Medium effort · Keyboard semantics

Diagnosis: what the measurements show together

Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.

Where the investment is most exposed · Value at risk
This code would cost about €150,000 to build again, about 1.0 person-years of work. Its weakest lens is Production Readiness, at 15.0 (Critical). Production Readiness is about whether the product is ready to run in production and to change without breaking. Because the weakest lens counts most in the score, work on Production Readiness also moves the score most.
Based on: the rebuild estimate · the Production Readiness grade · how much each lens counts
What to do: Start with the Production Readiness actions in Top priorities.
If you do one thing first · First action
Resolve the 5 Leaked secret finding(s) in REDACTED Scanning. Of all the actions in this report, it raises the score most for the work it takes: about 11.7 points for low effort, because it clears the 5 REDACTED Scanning findings. The next survey will show the change in the score.
Based on: the ranked actions in Top priorities, by score gain and effort
What hard-to-read code costs each year · Cost
Four dimensions measure how easy the code is to work in: two measure how tangled its logic is, one how much of it is copied, and one how well each part sticks to a single job. In this codebase they average 6.7 out of 10. Code at that level is slower to change than clean code, and we estimate the extra work at 3% to 7% on every change. The history of the code shows how much it changes: about 261,462 lines over the last 90 days, which is about 1,060,374 lines a year. At that pace, the extra work comes to an estimated 86.8 to 520.8 engineer-days a year, and it grows as more code changes.
How this is estimated: The number of changed lines is measured from the history of the code. The rest rests on two assumptions of our own: code scoring 8 out of 10 or more adds no extra work, and each point below 8 adds 2.5% to 5.6% to every change, never less than 2% to 5% and never more than 40% to 60% in all; and an engineer changes 150 to 400 lines in a day. The result is a range for planning, not a measurement.
Based on: Cyclomatic Complexity · Cognitive Complexity · Code Duplication · Cohesion (LCOM4) · the code's change history
What to do: Start with the files listed under Churn × Complexity Hotspots, which change often and are hard to read, because that is where the extra work is paid most often.

Architecture: which parts of the code depend on which

The code is divided into modules, groups of code that each handle one part of the product, and a module depends on another when it uses code from it. The table lists the modules both down the side and across the top, in an order where each module should only use modules listed above it. A number in a cell means the module on that row uses the module in that column, and it counts the pairs of building blocks (types) that connect them. The one thing to look for is a mark above the diagonal line. It means two or more modules use each other in a loop (a dependency cycle), so none of them can be changed, tested or released on its own.

72 modules, with 205 dependencies between them. One loop runs through 23 of the modules, marked above the diagonal.

The table shows the 40 modules with the most connections; 32 more are left out to keep it readable.

Which modules use which. The module on each row uses the module in each column, and the number counts the pairs of types that connect them. A cell above the diagonal is part of a loop.
uses →1 android.content2 com.solarized.firedown.ffmpegutils3 com.solarized.firedown.sabr4 com.solarized.firedown.sync.model5 com.solarized.firedown.applinks6 com.solarized.firedown.data.capture7 com.solarized.firedown.donation8 com.solarized.firedown.geckoview.media9 com.solarized.firedown.p2pshare10 com.solarized.firedown.settings.ui11 com.solarized.firedown.sync12 com.solarized.firedown.ui13 com.solarized.firedown.ui.browser14 com.solarized.firedown.geckoview.toolbar15 com.solarized.firedown.manager16 com.solarized.firedown.utils17 com.solarized.firedown.ui.adapters18 com.solarized.firedown.autocomplete19 com.solarized.firedown.geckoview20 com.solarized.firedown.data.entity21 com.solarized.firedown.data.dao22 com.solarized.firedown.phone.player23 com.solarized.firedown.ui.diffs24 com.solarized.firedown.data25 com.solarized.firedown.data.observer26 com.solarized.firedown.data.repository27 com.solarized.firedown.glide28 com.solarized.firedown.addons29 com.solarized.firedown.data.models30 com.solarized.firedown.data.workers31 com.solarized.firedown.geckoview.prompt32 com.solarized.firedown.manager.tasks33 com.solarized.firedown.data.di34 com.solarized.firedown.harness35 com.solarized.firedown.phone36 com.solarized.firedown.phone.fragments37 com.solarized.firedown.phone.dialogs38 com.solarized.firedown39 com.solarized.firedown.crash40 com.solarized.firedown.settings
1 android.content
2 com.solarized.firedown.ffmpegutils
3 com.solarized.firedown.sabr
4 com.solarized.firedown.sync.model
5 com.solarized.firedown.applinks1
6 com.solarized.firedown.data.capture26
7 com.solarized.firedown.donation1
8 com.solarized.firedown.geckoview.media21
9 com.solarized.firedown.p2pshare521
10 com.solarized.firedown.settings.ui9
11 com.solarized.firedown.sync151846
12 com.solarized.firedown.ui21
13 com.solarized.firedown.ui.browser7
14 com.solarized.firedown.geckoview.toolbar511
15 com.solarized.firedown.manager36414315
16 com.solarized.firedown.utils1111271
17 com.solarized.firedown.ui.adapters1033302134
18 com.solarized.firedown.autocomplete41147
19 com.solarized.firedown.geckoview146111218112
20 com.solarized.firedown.data.entity2115
21 com.solarized.firedown.data.dao7
22 com.solarized.firedown.phone.player12
23 com.solarized.firedown.ui.diffs16
24 com.solarized.firedown.data7226
25 com.solarized.firedown.data.observer111
26 com.solarized.firedown.data.repository4121313410
27 com.solarized.firedown.glide91252
28 com.solarized.firedown.addons522
29 com.solarized.firedown.data.models43119156122
30 com.solarized.firedown.data.workers111
31 com.solarized.firedown.geckoview.prompt232
32 com.solarized.firedown.manager.tasks45211
33 com.solarized.firedown.data.di33155692
34 com.solarized.firedown.harness1232191614821
35 com.solarized.firedown.phone3111111319
36 com.solarized.firedown.phone.fragments4138414842132324201361331223
37 com.solarized.firedown.phone.dialogs5121622101101551102933
38 com.solarized.firedown251224515361
39 com.solarized.firedown.crash31
40 com.solarized.firedown.settings9713246511439425
Uses a module listed above itPart of a loopThe module itself
1 android.content2 com.solarized.firedown.ffmpegutils3 com.solarized.firedown.sabr4 com.solarized.firedown.sync.model5 com.solarized.firedown.applinks6 com.solarized.firedown.data.capture7 com.solarized.firedown.donation8 com.solarized.firedown.geckoview.media9 com.solarized.firedown.p2pshare10 com.solarized.firedown.settings.ui11 com.solarized.firedown.sync12 com.solarized.firedown.ui13 com.solarized.firedown.ui.browser14 com.solarized.firedown.geckoview.toolbar15 com.solarized.firedown.manager16 com.solarized.firedown.utils17 com.solarized.firedown.ui.adapters18 com.solarized.firedown.autocomplete19 com.solarized.firedown.geckoview20 com.solarized.firedown.data.entity21 com.solarized.firedown.data.dao22 com.solarized.firedown.phone.player23 com.solarized.firedown.ui.diffs24 com.solarized.firedown.data25 com.solarized.firedown.data.observer26 com.solarized.firedown.data.repository27 com.solarized.firedown.glide28 com.solarized.firedown.addons29 com.solarized.firedown.data.models30 com.solarized.firedown.data.workers31 com.solarized.firedown.geckoview.prompt32 com.solarized.firedown.manager.tasks33 com.solarized.firedown.data.di34 com.solarized.firedown.harness35 com.solarized.firedown.phone36 com.solarized.firedown.phone.fragments37 com.solarized.firedown.phone.dialogs38 com.solarized.firedown39 com.solarized.firedown.crash40 com.solarized.firedown.settingsandroid.content1com.solarized.firedown.ffmpegutils2com.solarized.firedown.sabr3com.solarized.firedown.sync.model4com.solarized.firedown.applinks5com.solarized.firedown.data.capture6com.solarized.firedown.donation7com.solarized.firedown.geckoview.media8com.solarized.firedown.p2pshare9com.solarized.firedown.settings.ui10com.solarized.firedown.sync11com.solarized.firedown.ui12com.solarized.firedown.ui.browser13com.solarized.firedown.geckoview.toolbar14com.solarized.firedown.manager15com.solarized.firedown.utils16com.solarized.firedown.ui.adapters17com.solarized.firedown.autocomplete18com.solarized.firedown.geckoview19com.solarized.firedown.data.entity20com.solarized.firedown.data.dao21com.solarized.firedown.phone.player22com.solarized.firedown.ui.diffs23com.solarized.firedown.data24com.solarized.firedown.data.observer25com.solarized.firedown.data.repository26com.solarized.firedown.glide27com.solarized.firedown.addons28com.solarized.firedown.data.models29com.solarized.firedown.data.workers30com.solarized.firedown.geckoview.prompt31com.solarized.firedown.manager.tasks32com.solarized.firedown.data.di33com.solarized.firedown.harness34com.solarized.firedown.phone35com.solarized.firedown.phone.fragments36com.solarized.firedown.phone.dialogs37com.solarized.firedown38com.solarized.firedown.crash39com.solarized.firedown.settings40126121521915184621751136414315111127110333021344114714611121811221157121672261114121313410912525224311915612211123245211331556921232191614821311111131941384148421323242013613312235121622101101551102933251224515361319713246511439425+32 more modules (most-connected shown)

At a glance — Code Health · 42.0 · Weak · gated by D2, R1, X5 ·

At a glance — Architecture · 76.3 · Adequate · gated by D26 ·

At a glance — Maturity · 54.0 · Adequate · gated by M2 ·

At a glance — Readiness · 15.0 · Critical · gated by D13, R4, P1, P2, P3, P7 ·

At a glance — Security · 72.8 · Checked 4 of 10 · gated by D29 ·

At a glance — Accessibility · 27.5 · Weak · gated by AC1, AC4 ·

At a glance — Performance · 60.0 · Adequate ·

Security & Compliance — OWASP Top-10 mapping

Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).

OWASP categoryFindingsSeverity
A05:2025 — Injection67High / Critical
A07:2025 — Authentication Failures7High / Critical

Roadmap

Top priorities: Resolve the 5 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED; Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video; Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.

Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.

Do thisHelpsEffortDimension
Resolve the 5 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED.+11.7 ptsLowREDACTED Scanning
Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.+3.7 ptsMediumText alternatives
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.+3.7 ptsMediumKeyboard semantics
Add a CI workflow that builds and runs the test suite on every push/PR.+3.5 ptsMediumCI/CD gates
Run what this repository's stack ships: spotbugs with find-sec-bugs — or `semgrep --config=auto`, which runs on any language — locally for now, since there is no CI pipeline here yet, and as a step of the first workflow you add so a security regression fails the build instead of landing.+3.5 ptsMediumSecurity & performance tooling
Add tests that import the unreached modules (directly or through their public entry).+3.5 ptsMediumTest Coverage
Adopt SLF4J (with a Logback or Log4j2 JSON encoder) and log at meaningful points in the modules you run.+2.8 ptsMediumObservability
Resolve the 1 No ADRs found finding(s) in ADR Quality — start with build.gradle.+1.1 ptsLowADR Quality

File quality

Per-file score 0–10 — a quality signature. Of 305 files carrying findings, judged against the Production bar: 2% slop · 69% mixed · 29% near-clean.

FileScoreBandWorst signal
REDACTED0.0SlopREDACTED Scanning: Leaked secret: REDACTED
REDACTED0.1SlopREDACTED Scanning: Leaked secret: REDACTED
REDACTED0.6SlopStatic Analysis (SAST): High: REDACTED
REDACTED0.9SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.2SlopREDACTED Scanning: Leaked secret: REDACTED
REDACTED3.7SlopREDACTED Scanning: Leaked secret: REDACTED
REDACTED4.0MixedStatic Analysis (SAST): Medium: REDACTED
REDACTED4.4MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.9MixedStatic Analysis (SAST): Medium: REDACTED
REDACTED5.1MixedStatic Analysis (SAST): Medium: REDACTED
REDACTED5.4MixedStatic Analysis (SAST): Medium: REDACTED
app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java5.5MixedCyclomatic Complexity: DownloadFragment.observeViewModelData (cyclomatic 20)
app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java5.5MixedCyclomatic Complexity: PromptDelegate.onFileCallbackResult (cyclomatic 19)
app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java5.6MixedCyclomatic Complexity: SettingsFragment.onSharedPreferenceChanged (cyclomatic 26)
app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java5.6MixedCognitive Complexity: AutoCompleteSearch.mostVisited (cognitive 18)
app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java5.9MixedCyclomatic Complexity: DownloadsActivity.handleP2pDeepLink (cyclomatic 16)
app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java5.9MixedGod Classes: FileTooLong: settings/CloudBackupFileAdapter.java
app/src/main/java/com/solarized/firedown/utils/WebUtils.java6.0MixedExplicit Debt: TodoComment
REDACTED6.1MixedStatic Analysis (SAST): Medium: REDACTED
app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java6.3MixedGod Classes: TooManyMethods: BrowserDownloadEntity

How the grades work

Every finding carries one of four grades. Three say how serious it is. The fourth says this survey could not settle it — and it is a grade, not a gap.

Critical — 33

A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.

Serious — 1410

Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.

Minor — 116

Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.

Could not be resolved — 14

Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.

Methodology & how to trust this report

This survey is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. All 65 evaluated dimensions are computed by tools and static analysis; no language model sets or judges any of them. Overall confidence is 0.9, the weighted average across measured dimensions.

Every figure here is one of two kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10.

What we checked — 65 dimensions across the health lenses
D1D2D3D4D5D6D10D13D14D15D17D19D20D21D24D26D27D28D29D34D35D37D44AC1AC2AC3AC4AC6AX10AX2AX3AX4AX6GD1IC1M1M2M3P1P2P3P5P6P7PF3R1R10R2R3R4R7R9X16X18X2X20X21X24X25X27X28X29X3X30X5

Each chip is a dimension scored from real signals across architecture, testing, dependencies, security & compliance, documentation, git-history and code quality — in one coherent pass. A surface report typically covers a handful.

How to trust any code-health report — three questions
  1. Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 1549 of 1559 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
  2. Is there a tool behind the number? Every score below names the method that produced it: Roslyn, git or a scanner, not a narrative.
  3. Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.

This report answers yes to all three. That's the bar to hold any assessment to.

Tools & methods

The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.

MethodBacksVersionEvaluator
Roslyn static analysisComplexity, cohesion, coupling, dead code, API surface, layering5.3.0✓ deterministic
Native secret scannerHardcoded secrets / credentials1.0.0✓ deterministic
Canine Code Analyzer duplication detector (in-process)Code duplication1.0.0✓ deterministic
Coverage (coverlet / dotnet-coverage)Line & branch coverage10.0.400✓ deterministic
NuGet / dotnetOutdated, vulnerable & deprecated dependencies10.0.400✓ deterministic
git / LibGit2SharpChurn hotspots, knowledge concentration, history2.43.0 · 0.31.0✓ deterministic
gitleaks · semgrep · trivySecrets in history, SAST, CVEs, IaC & container, PII / GDPR1.86.0 · 0.69.3✓ deterministic

Every finding is locatable in findings.md. Run 01a1e7ce-f2cb-7cc6-a5d6-e9fd5ef3b4f7.

The exact command behind every deep-scan dimension — tool, version, invocation and retained raw output — is in Appendix B — Reproduction & audit trail.

Run transparency — what happened this run

What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.

  • D8 Code Coverage — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: test source is present (.java) but the built-in coverage collector has no runner for this repository's ecosystem — so this suite was never executed by it. Not scored — this is a gap in the analyzer's language coverage, not a defect in the repo.
  • D11 Test Reliability — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test source is present (.java) and this repository declares a JVM test suite (repository root, Gradle), but it was not re-run: no test result was produced. Not scored — this is a gap in the analyzer's language coverage, not a finding about this repository.
  • D12 Dependency Hygiene — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Not scored — 2 Maven/Gradle manifest(s) were read, stating a version for 41 dependency(ies) and leaving 2 to a parent or an imported BOM, but no build resolved the dependency graph, so the outdated signal was not established. NOT a finding that these dependencies are current or healthy.
  • D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (2 contributor(s) across 3218 commit(s) sampled, automation and bot accounts excluded). One of them holds 100% of the history; the other 1 hold 0% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
  • D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each ecosystem's manifests (what makes a folder runnable or a published package) need their own proof before D19 judges its units. Until then those folders' READMEs are judged only as documents (boilerplate, structure), never counted as complete.
  • D21 Naming Consistency — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. D21's naming rules read C# through Roslyn and every other language through its sidecar model; these languages are left out (PHP's reading is its own change, a Roslyn-loaded VB or F# project has no population builder yet). Their declarations carry no naming verdict this run — this says nothing about whether their names are consistent.
  • D21 Naming Consistency — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. PREREGISTRATION version 20's fallback (adjudication D21-sample3-v3): this rule kind was adjudicated below the 95 % precision gate, so its candidates are counted here and not published, and the score covers only the acronym-spelling and awaitable-suffix rules. The kind returns as rows only after it shows a measured precision; this says nothing about whether these names are consistent.
  • D22 Internal API Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22 identifies the intentionally-exposed surface from `IsPackable` and `.Contracts` project names, MSBuild conventions read off the loaded project set. This target exposed no such projects, so the probe never ran; this says nothing about whether the repository has a public API. This repository commits no C#/VB source at all, so there was never an MSBuild project set to read these conventions off. That is OUR side and it is a COLLECTOR gap, not an environment fault: no published-package marker D22 reads admitted any project here, so this ecosystem's public API has no collector, and the remedy is to write one — no change to the scan image can close it.
  • D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each source language's comment syntax, and the code a comment annotates in it, needs its own proof before D24 judges it. Until then those comments are left unread, not counted as clean.
  • D32 Data Compliance (PII/GDPR) — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `app/src/main/assets/webrequests/js/snapshot.js` produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
  • AC3 Page structure — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 49 further occurrence(s) are not listed individually; the score already reflects all 89.
  • AC6 Visual & motion safety — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 6 further occurrence(s) are not listed individually; the score already reflects all 46.
  • AXR1 Runtime accessibility — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Boot via AndroidApp (app). the Android app did not build — `./gradlew :app:assembleDebug` exited 1: 054c86ad767ee62f25bc59/settings.gradle' line: 55 * What went wrong: A problem occurred evaluating settings '.'. > scripts/fetch-prebuilts.sh failed (exit…; runtime evidence skipped (launch chosen because app/build.gradle applies the Android application plugin and gradlew builds it).
  • C1 Data Protection — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These personal data controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks personal data controls.
  • C2 Access Controls — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These authorization controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks authorization controls.
  • C3 Audit Trail — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These audit controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks audit controls.
  • C4 Data Retention — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These retention controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks retention controls.
  • C5 Data-Subject Rights — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These data-subject rights controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks data-subject rights controls.
  • R10 Code Duplication — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 1 further occurrence(s) are not listed individually; the score already reflects all 41.
  • S1 Web-Security Posture — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These web-security controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks web-security controls.
  • X1 Async correctness — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
  • X10 Duplicated predicate — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. 16 further occurrence(s) are not listed individually; the score already reflects all 56.
  • X12 Unreachable branch — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
  • X27 Collection changed while being enumerated — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X3 Exception handling — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 34 further occurrence(s) are not listed individually; the score already reflects all 74.

Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.

Limitations & what we did not check

We assess the repository exactly as committed, and only the repository. By design we do not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.

Per-dimension blind spots

For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.

  • D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
  • D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
  • D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
  • D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
  • D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
  • D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
  • D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
  • D13 REDACTED Scanning: REDACTED detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
  • D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
  • D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
  • D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
  • D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
  • D20 ADR Quality: ADR quality checks the structure of the decision records present: it cannot know about decisions made and never recorded, and it does not judge how well a record argues its case. Records in a language the section lexicon does not cover are not evaluated.
  • D21 Naming Consistency: Naming consistency compares each name with the convention its structural peers follow in this repository: it cannot tell whether a consistently used name is a good one, and languages other than C# and TypeScript are not measured.
  • D24 Comment Value: Comment value is measured as redundancy only: a comment that repeats its code's words is found, but a paraphrase in other words, a vague comment, or one the code contradicts is not, and whether a comment is valuable is not claimed. Comments in other scripts or languages, and outside C#, are not judged.
  • D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
  • D27 Navigability: Indirection/navigability is structural — it measures hops to follow a call, not whether that indirection buys real flexibility or just ceremony.
  • D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
  • D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
  • D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
  • D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
  • D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
  • AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
  • AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A click handler on a plain element is now asked for a name too (it is a control the author declared), but the subtree test that answers it is deliberately generous: any DYNAMIC text expression in the subtree counts as a name, so an icon chosen by a ternary ({cond ? <IconA/> : <IconB/>}) reads as named, and a glyph component from a library the icon-import list does not know still names its parent. A clean result is "no unlabelled control found", not a labelling proof.
  • AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
  • AC4 Keyboard semantics: Keyboard semantics are inferred from markup attributes — interactivity wired purely in script, focus managed at runtime, and component-level handlers are invisible. A clean result means "no static keyboard-trap shape", not a keyboard-operability proof.
  • AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
  • AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
  • P5 DR & Backup: Backup/restore and disaster-recovery readiness is judged from in-repo evidence — a config that exists is not a tested restore, so the absence of positive evidence is reported as "not evidenced", never scored as present.
  • P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.

Dimensions

D1 · Cyclomatic Complexity5.7 / 10Adequate✓ Tool-verified

What it measures: How tangled the control flow is — methods with many branches are hard to test and change.

Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.

Maturity: Documented → Verified → Prevented · effective 5.7 / 10 · rule-coverage 100% · ceiling Prevented

205 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was background.processVideo at 133. A further 13 method(s) were over the threshold but excluded as flat dispatchers (a long switch/match over independent cases: many branches, almost no nesting), the largest being FileUriHelper.getMimeTypeIcon at 36 — they are counted neither in the figure above nor in this dimension's score. 3 files carry no cyclomatic complexity row at all for this reason — every one of their over-threshold methods was excluded, so the exclusion is disclosed nowhere in the file itself: app/src/main/java/com/solarized/firedown/addons/AddonPermissionText.java (AddonPermissionText.icon at 29), app/src/main/java/com/solarized/firedown/utils/MessageHelper.java (MessageHelper.getResourceIdFromCode at 24), app/src/main/java/com/solarized/firedown/phone/player/PlayerSubtitles.java (PlayerSubtitles.mimeFor at 18). They are named here because the per-file figures other dimensions report are taken BEFORE this exclusion, so such a file can show a high maximum complexity elsewhere in this report and nothing here, with nothing to reconcile the two.

background.processVideo (cyclomatic 133)app/src/main/assets/youtube/background.js:1975
BrowserFragment.onViewCreated (cyclomatic 100)app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736
requests.emitCapture (cyclomatic 87)app/src/main/assets/webrequests/js/requests.js:1027
FileUriHelper.getFileExtensionFromMimeType (cyclomatic 64)app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:803
facebook.findNodeStarts (cyclomatic 57)app/src/main/assets/webrequests/js/parsers/facebook.js:119

+ 200 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Bring the 4 bodies over 60 down to 60 or less in Cyclomatic Complexity — start with background.processVideo (cyclomatic 133), BrowserFragment.onViewCreated (cyclomatic 100), requests.emitCapture (cyclomatic 87). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 4 together lifts Cyclomatic Complexity from 5.7 to about 6.5/10, projected with the scoring formula itself and assuming each lands exactly at 60; a cleaner split scores higher.

Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.

D2 · Cognitive Complexity3.6 / 10Weak✓ Tool-verified

What it measures: How hard the code is for a person to follow, beyond raw branching.

Method: Cognitive complexity per method (Sonar-style nesting-penalized score), computed exhaustively over production code, excluding test projects. Deterministic.

Maturity: Documented → Verified → Prevented · effective 3.6 / 10 · rule-coverage 100% · ceiling Prevented

299 method(s) exceeded the cognitive complexity threshold of 15; the worst was background.processVideo at 300.

page-state-bridge.collectPlayableMedia::walkNode (cognitive 89) · ×2app/src/main/assets/webrequests/js/page-state-bridge.js:1360
NavigationUtils.navigateSafe (cognitive 23) · ×2app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:69
NavigationUtils.navigateSafe (cognitive 21) · ×2app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:161
1.onCreateMenu (cognitive 17) · ×2app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:371
background.processVideo (cognitive 300)app/src/main/assets/youtube/background.js:1975

+ 290 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Bring the 3 bodies over 120 down to 120 or less in Cognitive Complexity — start with background.processVideo (cognitive 300), BrowserFragment.onViewCreated (cognitive 138), requests.emitCapture (cognitive 138). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 3 together lifts Cognitive Complexity from 3.6 to about 4.9/10, projected with the scoring formula itself and assuming each lands exactly at 120; a cleaner split scores higher.

Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.

D3 · God Classes8.0 / 10Strong✓ Tool-verified

What it measures: Over-large classes that try to do too much ("god classes").

Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.

Maturity: Documented → Verified → Prevented · effective 8.0 / 10 · rule-coverage 100% · ceiling Prevented

117 god class(es) detected.

TooManyMethods: BrowserFragment · ×48app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:136
FileTooLong: fragments/BrowserFragment.java · ×28app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java
ClassTooLong: BrowserFragment · ×25app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:136
MethodTooLong: BrowserFragment.onViewCreated · ×16app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736

What to do

  1. Resolve the 48 TooManyMethods finding(s) in God Classes — start with DownloadRequest.java (2), BrowserFragment.java, GeckoState.java. — One of this dimension's main actionable groups (48 warning-level).
  2. Resolve the 28 FileTooLong finding(s) in God Classes — start with BrowserFragment.java, AddonManager.java, P2pShareController.java. — One of this dimension's main actionable groups (28 warning-level).
  3. Resolve the 25 ClassTooLong finding(s) in God Classes — start with BrowserFragment.java, AddonManager.java, MediaViewerFragment.java. — One of this dimension's main actionable groups (25 warning-level).

Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.

D4 · Code Duplication7.7 / 10Strong✓ Tool-verified

What it measures: How much of the production code is copy-pasted: the share of production lines inside a reported copy (every copy of a duplicated block or of an edited member, each line once), 10 at none and 0 at a quarter of the lines.

Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), scored on the share of production lines inside a reported copy (each line once; 10 at none, 0 at a quarter). Deterministic.

Maturity: Documented → Verified → Prevented · effective 7.7 / 10 · rule-coverage 100% · ceiling Verified

234 duplicated block group(s) detected. 5.7 % of the production lines (9,474 of 164,866) are in a reported copy. A further 211 rows report members as variants of one another; the share counts each copied line once, however many rows cite it. 68 of the 445 are in trees this repository does not ship — vendored, example/demo, project-template, fixture and benchmark code — and are ranked below the shipped groups rather than excluded from them: the duplication there is real and is still counted in this dimension's score. The dimensions that publish a production-file census leave those trees out of theirs, so this count is deliberately drawn over the wider population.

Duplicated block (7 lines × 2) · ×25app/src/main/java/com/solarized/firedown/Preferences.java:939
Duplicated block (6 lines × 2) · ×22app/src/main/java/com/solarized/firedown/addons/AddonManager.java:759
Duplicated block (9 lines × 2) · ×19app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:221
Duplicated block (8 lines × 2) · ×18app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:96
Edited copy of a member (11 corresponding lines) · ×16app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:507

+ 134 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 25 Duplicated block (7 lines × 2) finding(s) in Code Duplication — start with REDACTED (2), Preferences.java, UpdateAvailableSheet.java. — One of this dimension's main actionable groups (25 warning-level).
  2. Resolve the 22 Duplicated block (6 lines × 2) finding(s) in Code Duplication — start with BaseDownloadFragment.java (2), AddonManager.java, DeezerStrategy.java. — One of this dimension's main actionable groups (22 warning-level).
  3. Resolve the 19 Duplicated block (9 lines × 2) finding(s) in Code Duplication — start with P2pReceiveFragment.java (2), AddonsHarness.java (2), REDACTED (2). — One of this dimension's main actionable groups (19 warning-level).

Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.

D5 · Coupling10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether volatile projects sit underneath others that depend on them (so their churn ripples upward), and whether project dependencies form cycles. A widely-depended-on but stable shared/kernel project is healthy, not penalised.

Method: Dependency cycles via elementary-DFS over real .csproj references, plus Martin instability (afferent/efferent) per project. Exhaustive over the reference graph, deterministic.

Coverage: Exhaustive · type-level: afferent/efferent coupling + cycles computed over every production type — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Prevented

3 production modules (Gradle+CMake), 0 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations; edges a convention plugin adds from buildSrc or build-logic are not visible there; 0 module(s) off the main sequence, with abstractness counted on 2 of the 3 (the rest declare no modelled class or interface, export only macros, declare types in source no model reads, or have no source directory of their own).

✓ On the Gold path — maintain.

Detailed fixes: d5_recommendation.md.

D6 · Cohesion (LCOM4)9.8 / 10Stronggated by 6 serious findings✓ Tool-verified

What it measures: Whether a class's methods are focused on a single responsibility.

Method: LCOM4 cohesion per production class with at least two methods: connected components of methods sharing state or calls, computed syntactically. Deterministic, not a proxy.

Coverage: Exhaustive · type-level: LCOM4 cohesion computed over every production class — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Verified

6 of 299 classes have LCOM4 above 3.

Low cohesion: DownloadFragment (LCOM4 8) · ×6app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:84

What to do

  1. Resolve the 6 Low cohesion finding(s) in Cohesion (LCOM4) — start with DownloadFragment.java, REDACTED, REDACTED. — One of this dimension's main actionable groups (6 warning-level).

Detailed fixes: d6_recommendation.md · top locations in Appendix A, every location in findings.md.

D10 · Test Quality9.9 / 10Stronggated by 1 serious finding✓ Tool-verified

What it measures: Whether the tests truly assert behaviour rather than just running the code.

Method: Per-test assertions, skips, and mock references analyzed via Roslyn; structured skip-reason tags (BUG:/ENV:) separate documented deferrals from debt. Deterministic.

Maturity: Documented → Verified → Prevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Prevented

0 skipped, 1 zero-assertion, no mocking-framework packages referenced (hand-written doubles or no mocking) across 252 tests.

No assertions: crockfordRejectsUapp/src/test/java/com/solarized/firedown/sync/crypto/CryptoTest.java:59

What to do

  1. Resolve the 1 No assertions finding(s) in Test Quality — start with CryptoTest.java. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d10_recommendation.md · top locations in Appendix A, every location in findings.md.

D13 · REDACTED Scanning0.0 / 10Critical✓ Tool-verified

What it measures: Whether any secrets (keys, tokens, passwords) have leaked into the code.

Method: In-process native secret scanner (entropy plus signature patterns) across all tracked files; no external tool. A clean result is a measured 10, not no-data zero. Deterministic.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Prevented

4 secret(s) detected. 1 detection(s) were excluded as holding no minted credential in material that runs: a name, reference or comparison rather than a value, a readable phrase or pattern, a value that declares itself fake, or development, test, example, mock or demo material.

REDACTED

What to do

  1. Resolve the 5 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED. — One of this dimension's main actionable groups (5 issue-level).

Detailed fixes: d13_recommendation.md · top locations in Appendix A, every location in findings.md.

D14 · License Compliance10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the licenses of third-party packages are compatible with your policy.

Method: Third-party package licenses resolved from declared package metadata and checked against the configured policy (allow/deny/copyleft). Deterministic; clean = no incompatible license found at metadata depth.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 16 declared JVM dependency artifact(s) use a banned license. Licences were resolved from the POMs Maven Central publishes, over the coordinates this repository's 2 Maven/Gradle manifest(s) declare with a version resolvable from the manifest itself — the same declaration-site closure this analysis reads for dependency currency. The JVM has no lockfile a checkout is guaranteed to carry, so this is deliberately NOT the transitive closure. 2 further coordinate(s) are declared with no version at the declaration site — inherited from a parent POM, a BOM or an unresolved Gradle version reference — and are NOT graded: this verdict covers what the checkout pins, not the full transitive graph. A further 25 coordinate(s) are not published to Maven Central — another repository (Google's Maven hosts androidx), a SNAPSHOT, or a private artifact — so their licences are not readable from here and they are outside this verdict.

✓ On the Gold path — maintain.

Detailed fixes: d14_recommendation.md.

D15 · Churn × Complexity Hotspots9.7 / 10Stronggated by 68 serious findings✓ Tool-verified

What it measures: Files that change often and are also complex — the riskiest hotspots.

Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.

Maturity: Documented → Verified → Prevented · effective 9.7 / 10 · rule-coverage 100% · ceiling Documented

Top hotspots: app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java (59×100=5900); app/src/main/assets/webrequests/js/requests.js (38×87=3306); app/src/main/assets/webrequests/js/page-state-bridge.js (15×108=1620) Repeated repair below the complexity floor: scripts/device-audit/selftest.mjs (3 of 4 changes were fixes)

Hotspot: app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java · ×67app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736
Repeated repair: scripts/device-audit/selftest.mjsscripts/device-audit/selftest.mjs:39

What to do

  1. Resolve the 67 Hotspot finding(s) in Churn × Complexity Hotspots — start with BrowserFragment.java, requests.js, page-state-bridge.js. — One of this dimension's main actionable groups (67 warning-level).
  2. Resolve the 1 Repeated repair finding(s) in Churn × Complexity Hotspots — start with selftest.mjs. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.

D17 · Explicit Debt10.0 / 10Stronggated by 3 serious findings✓ Tool-verified

What it measures: Acknowledged debt left in the code — TODOs, dead code, suppressed warnings.

Method: Roslyn syntactic debt markers (suppressions/TODO/FIXME/HACK/empty-catch/commented-code/Obsolete) plus SymbolFinder dead-code analysis; weighted-debt-per-KLoC density deducted 2.0x per unit. Deterministic, exhaustive.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Prevented

3 deducted task-comment markers across 164866 LoC (0.0/KLoC) → score 10.0. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.

TodoComment · ×3app/src/main/java/com/solarized/firedown/utils/WebUtils.java:285

What to do

  1. Resolve the 3 TodoComment finding(s) in Explicit Debt — start with WebUtils.java, RunnableManager.java, SvgDecoder.java. — One of this dimension's main actionable groups (3 warning-level).

Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.

D19 · Documentation Quality10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the project's documentation is clear, complete, and useful.

Method: Every README, docs/ document and root guide parsed by its markup and measured in Unicode letters. Published: a runnable or packaged .NET project whose README (or a document it links, or a root guide) shows no example, and a root README naming none of three or more projects. Overview, licence, boilerplate, wall-of-text, empty-section and XML-doc rows are measured and withheld (counted in gaps) after adjudication. Deterministic, exhaustive, advisory.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

1 of 1 documentation facets pass in full. 7 document(s) read across 1 unit(s).

✓ On the Gold path — maintain.

Detailed fixes: d19_recommendation.md.

D20 · ADR Quality0.0 / 10Critical✓ Tool-verified

What it measures: Whether architecture decisions are recorded well (context, decision, consequences).

Method: Every ADR read by its section structure: nine located rules (a missing Decision, Context or Consequences section, a stale status, two records deciding the same question, a dangling supersede link, a number-only title, a single option, no named cost, no status where the log uses one, no enforcement field where the log adopted one), each a fixed deduction from 10; the score is the mean over evaluated records. Deterministic, no model. Advisory.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

No architecture decision records were found.

No ADRs foundapp/build.gradle:2

What to do

  1. Resolve the 1 No ADRs found finding(s) in ADR Quality — start with build.gradle. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d20_recommendation.md · top locations in Appendix A, every location in findings.md.

D21 · Naming Consistency8.6 / 10Strong✓ Tool-verified

What it measures: Whether names — types, methods, variables — are clear and consistent.

Method: Seven vocabulary-free rules (N1-N7) mine each naming convention from the repository and flag a name that breaks a convention its structural peers in the same unit follow; production C# and TypeScript, each its own population. Deterministic, no model, no sample. Advisory.

Maturity: Documented → Verified → Prevented · effective 8.6 / 10 · rule-coverage 100% · ceiling Verified

6 naming inconsistencies among 442 declarations measured against a convention their peers follow.

`getDRMEnabled` spells `DRM` where 20 names in the project spell it `Drm`app/src/main/java/com/solarized/firedown/Preferences.java:929
`BrowserURIViewModel` spells `URI` where 70 names in the project spell it `Uri`app/src/main/java/com/solarized/firedown/data/models/BrowserURIViewModel.java:28
`setDRM` spells `DRM` where 20 names in the project spell it `Drm`app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1491
`NotificationID` spells `ID` where 424 names in the project spell it `Id`app/src/main/java/com/solarized/firedown/utils/NotificationID.java:5
`getID` spells `ID` where 424 names in the project spell it `Id`app/src/main/java/com/solarized/firedown/utils/NotificationID.java:52

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 1 `getDRMEnabled` spells `DRM` where 20 names in the project spell it… finding(s) in Naming Consistency — start with Preferences.java. — One of this dimension's main actionable groups (1 recommendation-level).
  2. Resolve the 1 `BrowserURIViewModel` spells `URI` where 70 names in the project spell… finding(s) in Naming Consistency — start with BrowserURIViewModel.java. — One of this dimension's main actionable groups (1 recommendation-level).
  3. Resolve the 1 `setDRM` spells `DRM` where 20 names in the project spell it `Drm` finding(s) in Naming Consistency — start with GeckoRuntimeHelper.java. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d21_recommendation.md · top locations in Appendix A, every location in findings.md.

D24 · Comment Value10.0 9.7 / 10Exemplary○ Nothing flagged

What it measures: Whether comments are worth it — explaining WHY (valuable) rather than WHAT (redundant).

Method: Every inline C# comment compared word by word with the identifiers, literals and constructs of the code it annotates (taken from the syntax); a comment whose words that code already contains is redundant, as are closing-brace labels and generator template text. Comments giving a reason or a reference are kept; other scripts and languages are not judged. Deterministic, exhaustive, advisory.

Maturity: Documented → Verified → Prevented · effective 9.7 / 10 · rule-coverage 97% · ceiling Documented

0 of 430 judged comments only repeat the code they sit on (0.0 %). 19 comment(s) in another language or script were not judged.

✓ On the Gold path — maintain.

Detailed fixes: d24_recommendation.md.

D26 · Project Cohesion0.0 / 10Critical✓ Tool-verified

What it measures: Whether each project is a focused, coherent unit rather than an oversized grab-bag.

Method: Project size overshoot penalties (LoC / public-type count / namespace count, 2-of-3 flag) weighted by log magnitude. Exhaustive across projects, deterministic.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

2 of 2 build units (Gradle) flagged as possibly oversized/incoherent.

Projects may be oversized for their cohesion · ×2app/build.gradle:1

What to do

  1. Resolve the 2 Projects may be oversized for their cohesion finding(s) in Project Cohesion — start with build.gradle (2). — One of this dimension's main actionable groups (2 recommendation-level).

Detailed fixes: d26_recommendation.md · top locations in Appendix A, every location in findings.md.

D27 · Navigability9.6 / 10Exemplary✓ Tool-verified

What it measures: How far you must trace to follow a call — low indirection and co-located slices read easier.

Method: Call indirection (interface hops, cross-namespace calls, slice-locality scaled) over a sampled set of method invocations, size-aware baseline. Sampled; confidence discounted by symbol-resolution gaps. C# also names each pass-through layer (a class whose every public method only forwards its own parameters to one collaborator) as a located finding; the score is not affected.

Coverage: Slice locality from the first namespace segments, SAMPLED (≤400 methods) — not exhaustive.

Maturity: Documented → Verified → Prevented · effective 9.6 / 10 · rule-coverage 100% · ceiling Documented

8 % of calls cross a namespace and 7 % go through an interface, but 97 % of collaborators are co-located — so a call's collaborators sit together and tracing stays easy. Baseline: small — navigation cost is tolerated.

✓ On the Gold path — maintain.

Detailed fixes: d27_recommendation.md.

D28 · Secrets (history)9.0 / 10Adequategated by 1 critical finding✓ Tool-verified

What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.

Method: REDACTED scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged High. Both invocations are recorded in the audit trail. Exhaustive; when the tool is absent, or when its output cannot be parsed into the expected shape, the dimension is WITHHELD as an explicit measurement gap on our side — unscored and excluded from the lens, never a hedged middling score.

Maturity: Documented → Verified → Prevented · effective 9.0 / 10 · rule-coverage 100% · ceiling Documented

1 finding(s): 0 critical, 1 high, 0 medium, 0 low. Remediation for historically-committed secrets is credential rotation — they remain in history regardless of later deletion.

REDACTED
REDACTED

What to do

  1. Resolve the 1 REDACTED finding(s) in Secrets (history) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  2. Resolve the 1 Rotate the exposed credentials finding(s) in Secrets (history). — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d28_recommendation.md · top locations in Appendix A, every location in findings.md.

D29 · Static Analysis (SAST)0.1 / 10Critical✓ Tool-verified

What it measures: Real static-analysis (SAST) findings — likely security bugs in the code, any language.

Method: Polyglot static analysis via semgrep across the repo using the pinned, image-baked p/security-audit + p/owasp-top-ten rulesets (no scan-time registry fetch); severity rules (ERROR/WARNING/INFO) map to a full-band severity-weighted score. Exhaustive, deterministic; degrades on parse failure.

Coverage: semgrep pattern rules over all files — exhaustive for the rule set, blind to classes of bug without a rule (clean = no rule matched).

Maturity: Documented → Verified → Prevented · effective 0.1 / 10 · rule-coverage 100% · ceiling Documented

69 finding(s): 0 critical, 9 high, 57 medium, 3 low. semgrep hit a parse error in 12 file(s) — `app/src/main/assets/webrequests/js/content-script.js`, `app/src/main/assets/webrequests/js/snapshot.js` (lines 103–993), `app/src/main/assets/youtube/background.js`, `gradlew` (line 74, line 180), `scripts/backup-sim-harness/run.sh` (line 152), … (+7 more) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

+ 10 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 3 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (3 issue-level).
  2. Resolve the 3 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (3 issue-level).
  3. Resolve the 3 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (2), REDACTED. — One of this dimension's main actionable groups (3 issue-level).

Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.

D34 · Knowledge Freshness10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still has living knowledge of each file, or it has been orphaned — last understood long ago by someone now gone quiet. The sibling of the bus factor: D16 asks who owns it, D34 asks whether anyone still knows it.

Method: File orphaning as total living-knowledge decay below one focused-commit's worth within a year, computed per-file from the D16 decay model. Exhaustive, deterministic over fixed history.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

Every significant source file has living knowledge — recently and meaningfully worked. Counted over 548 of the 975 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.

✓ On the Gold path — maintain.

Detailed fixes: d34_recommendation.md.

D35 · Change Coupling9.9 / 10Stronggated by 8 serious findings✓ Tool-verified

What it measures: Whether files that change together actually belong together — pairs that repeatedly co-change in git history despite having no explicit code dependency, surfacing the hidden/logical coupling (and boundaries in the wrong place) a static scan can't see.

Method: Pairwise co-occurrence over the per-commit file sets in git history (production source only — tests and generated dropped): Degree-of-Coupling = shared ÷ min individual revisions, reported above noise floors (each file ≥10 revisions, ≥5 shared commits, ≥50% strength); sweeping commits excluded. Deterministic over fixed history.

Coverage: Population: PRODUCTION source files only — test and generated files are dropped before pairing, so a class co-changing with its own test (trivially ~100%) can't drown the real production↔production coupling. Pairs ranked by Degree-of-Coupling. A non-source file is never a coupling PARTICIPANT either: documentation, schemas, config and data files are dropped with the rest, so a code↔docs pair — a command and the reference page that restates it — is not reported however strongly the two co-change; nor is coupling that runs THROUGH a build step or config file.

Maturity: Documented → Verified → Prevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Documented

Strongest change-coupling: DownloadDao.java↔DownloadDataRepository.java 93%; BrowserDownloadEntity.java↔GeckoInspectEntity.java 64%; DownloadDao.java↔HomeFragment.java 60%

Change coupling: DownloadDao.java ↔ DownloadDataRepository.java · ×8app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java:1

What to do

  1. Resolve the 8 Change coupling finding(s) in Change Coupling — start with DownloadDao.java (2), BrowserDownloadEntity.java (2), CloudBackupFileAdapter.java. — One of this dimension's main actionable groups (8 warning-level).

Detailed fixes: d35_recommendation.md · top locations in Appendix A, every location in findings.md.

D37 · Vulnerability-disclosure Policy10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the repository publishes a coordinated-vulnerability-disclosure policy (SECURITY.md or security.txt) with a reporting contact, so finders know how to report a vulnerability. Presence of a policy file with a contact, not whether the policy is adequate or honoured.

Method: Vulnerability-disclosure policy read deterministically from the repo: a SECURITY.md (root/.github/docs) or .well-known/security.txt / security.txt, regex-checked for a reporting contact (email / URL / mailto). Present + contact → 10; present without a contact → 4; NotApplicable when no policy file exists (it may live off-repo). Detects the policy file's presence + contact, not its adequacy.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

A vulnerability-disclosure policy (SECURITY.md) is published with a reporting contact.

✓ On the Gold path — maintain.

Detailed fixes: d37_recommendation.md.

D44 · Platform End-of-Life10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still ships security patches for the platform this repository RUNS ON — the runtime it pins and the framework majors its own constraints hold it to. Separate from D12 because the question differs: a current Django on an end-of-life Python is perfectly up to date and completely unsupported, and the fix is a migration rather than a version bump. What the repository says it merely SUPPORTS is never charged.

Method: End-of-life PLATFORM read from the repository's own declarations and graded against a FROZEN, dated table of vendor support dates — no network, no feed, no API, so this dimension answers identically inside a closed scan fence. Two subjects: a RUNTIME the project pins (a single or all-end-of-life TargetFramework, a .nvmrc or .python-version, a requires-python CAP) and a FRAMEWORK major a dependency constraint cannot move off (a caret, tilde or exact version; `vue@^2.7.16` pins Vue 2). A FLOOR is deliberately never charged — `requires-python = ">=3.8"` states what a package SUPPORTS, not what it runs on — and a multi-target project is charged only when EVERY target is out of support. Runtime 4.0/product capped 8.0, framework 1.5 capped 4.5. The table is safe to freeze because a statement about support that ended in the past cannot become false: it loses recall as it ages, never precision, and a test asserts every entry predates the freeze date. Disjoint from D31 (a container image's OS layer) and D29 (the toolchain a CI workflow installs). Abstains when the repository declares no platform this pass reads — never scores it clean.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

0 end-of-life runtime(s) and 0 end-of-life framework(s), read from 1 platform declaration(s) and 42 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a Rust toolchain pin, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.

✓ On the Gold path — maintain.

Detailed fixes: d44_recommendation.md.

Frontend & cross-cutting dimensions

R = React/JS · M = Maturity · P = Readiness.

AC1 · Text alternatives1.0 / 10Critical✓ Tool-verified

Other · Accessibility — Whether non-text content carries a text alternative — img/area/input[type=image] have alt, a meaningful svg has a title or aria-label, video has a captions track, and object/embed/canvas have a name or fallback content. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: every img/area/input[type=image] checked for alt, svg[role=img] for a title/aria-label, video for a captions <track>. Components skipped, spreads suppressed. Deterministic, hard fact per element.

Coverage: Population: image/media elements — img, area, input[type=image], svg, video, object, embed, canvas — across the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and dynamic-attribute elements are skipped. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is NOT read by any producer, so it contributes no element to this population; where such a frontend is present the card discloses it as an analyzer gap rather than scoring around it.

  • An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative. (×2) — design/home-incognito-illus.html:20, design/inc_landscape.html:16

What to do

  • Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
AC2 · Forms & labels4.0 / 10Weak✓ Tool-verified

Other · Accessibility — Whether form controls have a programmatic label (an associated label, aria-label or aria-labelledby), buttons have text, links have an accessible name, a click handler on a plain element names the control it declares, fieldsets have a non-empty legend, known UI-library field components carry a label prop, and a placeholder isn't used as the only label. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: inputs/selects/textareas checked for an associated label[for]/wrapping label/aria-label/aria-labelledby (per document), buttons for accessible text, fieldsets for a legend; placeholder-only labelling flagged. Deterministic, hard fact per control.

Coverage: Population: form controls, buttons, links, fieldsets and known UI-library field components in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and spread/dynamic-attribute elements are skipped, so a control whose label arrives through a spread or a runtime expression is deliberately not judged. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id. (×2) — sketches/bookmark-edit-improvements.html:513, sketches/bookmark-edit-improvements.html:517
  • This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. (×6) — sketches/bookmark-edit-improvements.html:514, sketches/bookmark-edit-improvements.html:518, sketches/home-ember-tuner.html:98, …
  • This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label. — sketches/browsesubtitlegrouping.html:592

What to do

  • Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.
AC3 · Page structure5.1 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether pages declare a language (well-formed BCP-47) and a non-empty title, expose exactly one main landmark and a sane heading order with non-empty headings, keep zoom enabled, title their iframes, give data tables header cells, and avoid meta-refresh. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: html lang, document <title>, a main landmark and heading order on full documents only, plus zoom-disabling viewports, untitled iframes and meta-refresh anywhere. Deterministic, per structural checkpoint.

Coverage: Population: the PARSED MARKUP documents (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx). The page-level checks — lang, title, single main landmark — fire ONCE PER FULL DOCUMENT (an <html> root) and never on a partial or component fragment, so a repo of fragments is assessed only on the per-element checks (heading order, table headers, iframe titles, meta-refresh, zoom). Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. (×23) — design/home-card-border-options.html:2, design/home-flame-glow.html:2, design/home-incognito-illus.html:1, …
  • The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en"). (×4) — design/home-incognito-illus.html:1, design/inc_landscape.html:1, design/pills_card.html:1, …
  • A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>. (×3) — design/home-incognito-illus.html:1, design/inc_landscape.html:1, design/pills_card.html:1
  • Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one. (×10) — design/home-minimal.html:80, design/home-mockups-minimal.html:126, design/home-mockups.html:206, …

What to do

  • Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
AC4 · Keyboard semantics1.0 / 10Critical✓ Tool-verified

Other · Accessibility — Whether interactive behaviour is keyboard-reachable — no click handler on a non-interactive element lacking a role, tabindex and key handler, no element the repo's own CSS styles `cursor: pointer` without giving it any of the three, no unfocusable element whose only binding is a mouse enter/leave pair or a double-click, no positive tabindex, no href-less anchor, no placeholder-href (#/javascript) link acting as a button. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: click handlers on non-interactive elements lacking role+tabindex+key handler, positive tabindex values, and href-less anchors. Components skipped, spreads suppressed. Deterministic, hard fact per element.

Coverage: Population: elements that pose a keyboard-semantics question, in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx) — a non-natively-interactive element carrying a click handler, a double-click or hover enter/leave binding, a pointer-only gesture on a tabindex="0" element, or `cursor: pointer` from the repo's own CSS; an href-less or placeholder-href (#, javascript:) anchor; and any element with a positive tabindex. Natively interactive elements used correctly (<button>, <a href>, form controls) are NOT in the population — there is nothing to judge — so a page of nothing but correct controls gives AC4 nothing to measure. Keyboard reachability is judged from the markup, never from a rendered page. ★ An interactive element declared in a tagged-template (html`…`) or hyperscript frontend is NOT in this population — no producer reads either — so an empty population is reported as an analyzer gap, never as "this repository has no interactive elements".

  • An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action. (×2) — design/home-mockups.html:213, design/home-mockups.html:245

What to do

  • Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
AC6 · Visual & motion safety7.0 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether focus outlines aren't removed without a replacement, motion respects prefers-reduced-motion, and literal CSS colour pairs meet contrast — PARTIAL: inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS literals are read (hex/rgb/hsl/named), never computed/runtime/external-CDN colour. Static markup readiness, not a WCAG conformance claim.

Method: Static markup/CSS scan: inline outline:none/0, literal inline colour/background contrast against the 4.5:1 AA floor, and <style>-block animation without a prefers-reduced-motion guard. Deterministic but PARTIAL — only inline styles and in-repo CSS literals are visible.

Coverage: Population: styled elements in the PARSED MARKUP files (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx), plus in-repo <style> blocks, in-repo .css files and CSS-in-JS literals. Colour contrast is computed from LITERAL colour pairs only (hex/rgb/hsl/named, including var() tokens and Tailwind neutral utilities) — computed, runtime-themed and external-CDN colour is never resolved, so this is a partial read of contrast by construction. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • `.optlbl .pill` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-card-border-options.html:15
  • `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×6) — design/home-card-border-options.html:24, design/home-incognito-minimal.html:18, design/home-minimal-final.html:17, …
  • `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×5) — design/home-card-border-options.html:24, design/home-minimal-final.html:17, design/home-minimal.html:26, …
  • `.cta` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×3) — design/home-card-border-options.html:49, design/home-onboarding-borderless.html:29, design/home-onboarding-final.html:36
  • `.phone.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-incognito-logo.html:29
  • `.badge` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×3) — design/home-incognito-minimal.html:32, design/home-minimal-final.html:25, design/home-minimal.html:49
  • `.tag` sets color: #fff on background-color: #9a98a6 — 2.8:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×3) — design/home-minimal.html:13, design/home-stats-alternatives.html:13, design/home-subtitle-options.html:20
  • `.dark .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×2) — design/home-mockups-minimal.html:43, design/home-mockups.html:72
  • `.cap .tag` sets color: #fff on background-color: #FF5A1F — 3.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-onboarding-zero.html:34
  • `.omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-onboarding-zero.html:52
  • `.step .n` sets color: #FF5A1F on background-color: #FFEDE5 — 2.7:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-onboarding-zero.html:73
  • `.cta` sets color: #fff on background-color: #FF5A1F — 3.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — design/home-onboarding-zero.html:81
  • The inline foreground/background colours fall below the 4.5:1 WCAG AA minimum for normal text. Darken/lighten one of them. (×2) — sketches/addons.html:467, sketches/errorcolorpreview.html:114
  • `.fav.so` sets color: #fff on background-color: #f48024 — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — sketches/bookmarks-card-sketches.html:133
  • `.fav.mz` sets color: #fff on background-color: #ff7139 — 2.7:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — sketches/bookmarks-card-sketches.html:134
  • `.fav.yt` sets color: #fff on background-color: #ff0000 — 4.0:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — sketches/bookmarks-card-sketches.html:135
  • `.fav.gn` sets color: #fff on background-color: #4285f4 — 3.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — sketches/bookmarks-card-sketches.html:136
  • `.breathing .glow` moves (`animation: breathe var(--speed,2.6s) ease-in-out infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — sketches/home-ember-tuner.html:39
  • `.active-dl .ember` moves (`animation: breathe 2.4s ease-in-out infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — sketches/home-slickness-directions.html:71
  • `.flare .ember` moves (`animation: flare .9s ease-out 1`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — sketches/home-slickness-directions.html:78
  • `.flare .pop` moves (`animation: pop .9s ease-out 1`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — sketches/home-slickness-directions.html:83
  • `.mini-spin` moves (`animation: spin .8s linear infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — sketches/home-slickness-directions.html:88
  • `.toolbar .urlbar` sets color: #8b8794 on background-color: #2a2a2e — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — sketches/home-ux-alternatives.html:125

What to do

  • Keep a visible focus style (don't remove the outline without a replacement), guard animation with prefers-reduced-motion, and raise low-contrast colour pairs to at least 4.5:1.
AX10 · Code composition8.9 / 10Strong✓ Tool-verified

Other · Architecture — How the codebase splits by code ROLE — domain, application, infrastructure, test, generated. The significance map behind the knowledge/coupling weighting, and a DDD signal in its own right: a thin domain core under fat infrastructure is the anemic-domain smell, quantified. How each file's role is decided, because the split is only as good as that: a generated name or a build-output tree makes it Generated, a test project makes it Test, and otherwise the file's NAMESPACE and PATH words are matched against fixed vocabularies in a fixed ORDER — domain, then infrastructure, then application — so a file whose words hit two layers is counted under the earlier one. A production file matching none of them counts as application, so that share reads 'application or unclassified' rather than a measured application layer. Roles come from naming convention, never from what the code does. On this repository the split was taken from the source tree on disk rather than from a loaded .NET workspace, so a file's role is decided by its PATH segments alone — no declared namespace was available to add to the evidence — and generated output is excluded from the census entirely rather than counted as a generated share.

Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.

Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.

AX2 · Stateful singletons4.6 / 10Weak✓ Tool-verified

Other · Architecture — Whether singleton services avoid mutable shared instance state that concurrent callers would race on.

Method: Roslyn scan: singleton field mutations unguarded by lock or Interlocked, per type; syntax-based guard detection. Deterministic, traceable per field.

  • `AddonManager` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mActions, mInstalled, mPageInstallInFlight, mDeclinedHosts, mPromptQueue, mRuntime; e.g. `mActions` in `actionState` at line 1931). — app/src/main/java/com/solarized/firedown/addons/AddonManager.java:88
  • `AmoCatalogClient` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mLoading; e.g. `mLoading` in `load` at line 93). — app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:48
  • `SearchRepository` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mEngineCache; e.g. `mEngineCache` in `loadSearchEngines` at line 82). — app/src/main/java/com/solarized/firedown/data/repository/SearchRepository.java:32
  • `TaskRepository` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mRunningTaskSeq; e.g. `mRunningTaskSeq` in `trackRunningTask` at line 234). — app/src/main/java/com/solarized/firedown/data/repository/TaskRepository.java:29
  • `GeckoComponents` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mPendingLocation; e.g. `mPendingLocation` in `onLocationPermissionResult` at line 327). — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:79
  • `GeckoObserverRegistry` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mObservers; e.g. `mObservers` in `register` at line 63). — app/src/main/java/com/solarized/firedown/geckoview/GeckoObserverRegistry.java:49
  • `P2pShareController` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mRecvPartFile, mWakeLock, mWifiLock, mRuntime, mSessionRegistrar, mState; e.g. `mRecvPartFile` in `acceptOffer` at line 1548). — app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:123
  • `Sorting` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mCurrentSortDownloads; e.g. `mCurrentSortDownloads` in `setCurrentSortDownloadsForId` at line 48). — app/src/main/java/com/solarized/firedown/Sorting.java:12

What to do

  • Java/Kotlin: keep container singletons stateless — move per-request data into locals or a request-scoped bean — or back the state with java.util.concurrent types (ConcurrentHashMap, AtomicInteger/AtomicReference), guard it with synchronized / a Lock (Kotlin: withLock), or mark a flag that is only ever overwritten volatile (@Volatile).
AX3 · Project dependency cycles10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether the project-reference graph is acyclic (cycles block independent build/deploy and signal eroding boundaries).

Method: Project reference cycles via elementary-DFS over real .csproj references, using the engine shared with D5/D7; cyclic versus acyclic. Exhaustive, deterministic.

AX4 · Dependency direction10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.

Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.

AX6 · Interface segregation9.6 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether interfaces stay focused rather than fat — the Interface-Segregation principle (SOLID 'I').

Method: Roslyn scan: public interface declared-member counts (accessors fold into their property/event); fat-interface threshold (over 15 declared members) flagged per type. Each finding also reports the distinct-OPERATION count — members counted by name, so an overload group counts once — which decides whether it states the caller-side ISP harm or the implementer-side burden of an overload set. TypeScript: exported interfaces that declare behaviour, counted over their REQUIRED operations (method signatures and function-typed properties with no `?`, once per signature) — data-shape interfaces and ambient .d.ts declarations are outside the population; JavaScript declares no interfaces and is not applicable. Deterministic, type-level.

  • `Phone` declares 18 abstract methods under just 15 distinct name(s): `account`, `backup`, `cancelBackups`, `delete`, `delete`, `deleteAll`, `describe`, `list`, `name`, `open`, `open`, `restore`, `restore`, `setClockOffset`, `setCode`, `sweepUploadsNow`, `useDav`, `useS3`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. That is an OVERLOAD SET, not 18 separate responsibilities: a caller binds to 15 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 18 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface. — scripts/backup-sim-harness/src/simapi/Phone.java:16
  • `DownloadDao` declares 36 abstract methods: `deleteAll`, `deleteSync`, `deleteSyncEntities`, `deleteSyncEntity`, `findByFilePath`, `findById`, `findByIdSync`, `findByNameSize`, `findPlayerCompanions`, `getAllIds`, `getAllRaw`, `getAllRawEnc`, `getAllRawList`, `getAllRegularLive`, `getAllSafeLive`, `getCaptureStatesLive`, `getDownloads`, `getDownloadsDomain`, `getDownloadsName`, `getDownloadsSize`, `getRegularFinishedCount`, `getRegularFinishedSizeLive`, `getRegularFinishedSync`, `getRegularUsageByMimeLive`, `getRowCount`, `getSafe`, `getSafeDomain`, `getSafeName`, `getSafeRowCountLive`, `getSafeSize`, `insert`, `insertAll`, `insertSync`, `search`, `setParentId`, `setThumbnailUnavailableSync`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java:18
  • `WebBookmarkDao` declares 20 abstract methods: `delete`, `deleteAll`, `deleteById`, `gcTombstones`, `getAllForSync`, `getAllIds`, `getAllRaw`, `getAutoCompleteSearch`, `getBookmark`, `getBookmarks`, `getBookmarksAlphabetical`, `getId`, `getRowCount`, `insert`, `insertAll`, `search`, `softDelete`, `softDeleteAll`, `updateIcon`, `updateTitleIfPlaceholder`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/data/dao/WebBookmarkDao.java:17
  • `WebHistoryDao` declares 18 abstract methods: `delete`, `deleteAll`, `deleteById`, `deleteRange`, `getAutoCompleteFts`, `getAutoCompleteHistory`, `getAutoCompleteSearch`, `getHistory`, `getHistory`, `getHistorySync`, `getLatestWithIcon`, `getMostVisited`, `getRowCount`, `getSearch`, `insert`, `purgeDatabase`, `updateIcon`, `updateTitleByUrl`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. Those 18 declarations carry 17 distinct name(s), so part of the width is overloading rather than separate responsibilities — but 17 operations clears the >15 bar on its own, so the row is about responsibilities, not signatures. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/data/dao/WebHistoryDao.java:20
  • `Download` declares 25 abstract methods: `getDuration`, `getDurationFormatted`, `getFileDate`, `getFileDescription`, `getFileErrorType`, `getFileHeaders`, `getFileImg`, `getFileIsLive`, `getFileLanguage`, `getFileMimeType`, `getFileName`, `getFilePath`, `getFileProgress`, `getFileResolution`, `getFileSize`, `getFileStatus`, `getFileType`, `getFileUrl`, `getId`, `getOriginUrl`, `getParentId`, `getThumbnailDuration`, `isFileEncrypted`, `isFileSafe`, `isFileThumbnailUnavailable`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/data/Download.java:3
  • `TabState` declares 19 abstract methods: `canGoBackward`, `canGoForward`, `getCertificateState`, `getCreationDate`, `getIcon`, `getId`, `getParentId`, `getPreview`, `getSessionState`, `getTabId`, `getTitle`, `getUri`, `isActive`, `isDesktop`, `isFirstContentFulPaint`, `isFullScreen`, `isHome`, `isIncognito`, `isSearchMode`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/data/TabState.java:6
  • `GeckoObserver` declares 44 abstract methods: `onClose`, `onContentPermission`, `onContext`, `onCrash`, `onDownload`, `onDrmDisabled`, `onFirstComposite`, `onFullScreen`, `onHideBars`, `onKill`, `onLoadRequest`, `onLocationChange`, `onMediaActivated`, `onMediaDeactivated`, `onMediaMetadata`, `onMediaPause`, `onMediaPlay`, `onMediaPosition`, `onMediaRefused`, `onMediaStop`, `onMetaViewportFitChange`, `onNew`, `onOrientation`, `onPointerIconChange`, `onPromptAlert`, `onPromptAuth`, `onPromptButton`, `onPromptChoice`, `onPromptColor`, `onPromptDate`, `onPromptFile`, `onPromptRepost`, `onPromptShare`, `onPromptText`, `onPromptUnload`, `onScrollChange`, `onSecurityChange`, `onShowDynamicToolbar`, `onStart`, `onStop`, and 4 more. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — app/src/main/java/com/solarized/firedown/geckoview/GeckoObserver.java:13

What to do

  • Split fat interfaces into focused role-interfaces so clients depend only on what they use.
  • Where the width is an overload set rather than separate responsibilities, collapse the overloads instead — segregating those relieves no caller.
GD1 · Unfinished & placeholder code10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unreviewed-generation residue in this repository's Java: methods whose whole body only throws a "not implemented" or bare unsupported-operation exception, or returns a default value (or nothing) under a TODO/FIXME marker, and placeholder text (lorem ipsum, changeme/replace_me…) left in strings of non-test, non-generated code. Scored as a quality signature, never as a claim about authorship.

Method: Roslyn syntax scan: NotImplementedException throws and placeholder string literals in non-test, non-generated shipped code. Deterministic, code-shape signature.

IC1 · Incompleteness & stubs10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unfinished work detected by code SHAPE, not keywords, in this repository's Java: methods that only throw a "not implemented" exception, methods that take inputs and return a constant or do nothing, dead `if (false)` branches, and skeleton classes most of whose methods are holes.

Method: Roslyn syntax scan: incompleteness by code shape (constant-returning methods, async-never-await, #if false branches, guards that return what the code already falls through to, tests an earlier guard already decided, comparisons against NaN, skeleton types), not keyword-gated. Deterministic, code-shape heuristic.

  • `@SuppressWarnings("all")` switches every compiler and analyser warning off for the whole declaration — hidden debt. Suppress the specific warning on the specific member, with a justification, instead. (×2) — app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:89, app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:103

What to do

  • Clear the softer debt: re-enable or delete @Disabled/@Ignore tests, decide whether each empty method or UnsupportedOperationException is deliberate (and say so in a comment), and replace @SuppressWarnings("all") with targeted, justified suppressions.
M1 · Documentation (README)6.7 / 10Adequate✓ Tool-verified

Maturity · Maturity — Whether the repository and its projects have a README, and whether it is substantive.

Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.

What to do

  • Explain in the README how to run the tests. Add a section called Testing to the README in the repository's top folder, saying how to run the test suite.
M2 · Architecture documentation0.0 / 10Critical✓ Tool-verified

Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.

Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.

  • No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
  • No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named `architecture` or `design` in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape — no `## Architecture` heading, no "architecture overview"/"high-level design" phrasing, no "the architecture is …" introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document — not evidence that nobody wrote the shape down.

What to do

  • Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
  • Add a C4 context/container diagram (Structurizr, PlantUML or Mermaid) or an architecture.md overview.
M3 · Folder & project structure10.0 / 10Exemplary✓ Tool-verified

Maturity · Maturity — Whether the repository is organised deliberately: production code and tests are set apart in a way its ecosystem or the repository itself declares.

Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.

P1 · CI/CD gates0.0 / 10Critical✓ Tool-verified

Readiness · Readiness — Whether an automated pipeline builds and tests every change.

Method: Filesystem scan: CI workflow files (.github/workflows, .gitlab-ci.yml, etc.) for build and test stages. Exhaustive, deterministic.

  • No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, …) — changes aren't gated by an automated build/test.

What to do

  • Add a CI workflow that builds and runs the test suite on every push/PR.
P2 · Observability1.0 / 10Critical✓ Tool-verified

Readiness · Readiness — Whether the code is diagnosable in production — structured logging, tracing/metrics, health checks.

Method: Filesystem/Roslyn scan: structured-logging frameworks (Serilog, NLog), OpenTelemetry, and health-check endpoint patterns. Exhaustive, deterministic.

  • No logging call was found in the 666 JavaScript/TypeScript, JVM production file(s) this check read across 2 module(s). Each was searched for its ecosystem's logging libraries (JVM: SLF4J, Log4j2, java.util.logging, Logback, kotlin-logging, scala-logging; JavaScript/TypeScript: pino, winston, bunyan, log4js, loglevel, consola, the NestJS Logger) and for a call on a receiver named `log`/`logger` (or ending in `Logger`/`_logger`) with a level verb. It cannot see logging through a repo-local wrapper named otherwise, or in source it did not read — this is 'no logging found by this walk', not a verdict that nothing here logs. If it is right, production issues will be hard to diagnose.

What to do

  • Adopt SLF4J (with a Logback or Log4j2 JSON encoder) and log at meaningful points in the modules you run.
P3 · Security & performance tooling0.0 / 10Critical✓ Tool-verified

Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).

Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.

  • No static application security testing detected. For this repository's stack, add spotbugs with find-sec-bugs (or `semgrep --config=auto`, which runs on any language) — this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
  • `build.gradle` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`. — build.gradle:8

What to do

  • Run what this repository's stack ships: spotbugs with find-sec-bugs — or `semgrep --config=auto`, which runs on any language — locally for now, since there is no CI pipeline here yet, and as a step of the first workflow you add so a security regression fails the build instead of landing.
  • Enable Dependabot/Renovate or a dependency-review gate.
  • Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P5 · DR & Backup4.0 / 10Weak✓ Tool-verified

Readiness · Readiness — Whether disaster recovery is planned and codified — backups, geo-recovery, RTO/RPO, persistence guarantees — from IaC + container manifests + docs, never the live cloud.

Method: Filesystem scan: disaster recovery, backup, geo-recovery, RTO/RPO, persistence guarantees from IaC, manifests, and docs. Exhaustive, deterministic, never a live environment.

What to do

  • Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery).
P6 · Release Hygiene10.0 / 10Exemplary✓ Tool-verified

Readiness · Readiness — Whether releases are traceable — a maintained changelog and explicit version stamping.

Method: Filesystem scan: changelog file presence and version tags in csproj or git tags. Exhaustive, deterministic.

P7 · Outbound HTTP resilience3.0 / 10Weak✓ Tool-verified

Readiness · Readiness — Whether outbound HTTP calls are wrapped in resilience (retry/timeout/circuit-breaker) so a failing dependency doesn't cascade.

Method: Source scan: outbound HTTP clients and what bounds them — resilience handlers (Polly, AddStandardResilienceHandler) on .NET; on Go, the JVM, Python, JavaScript/TypeScript, Ruby, PHP, Rust, Elixir, Swift, Dart and Erlang, a timeout, deadline, retry or breaker beside each call, or a process-wide client default (a framework-wide deadline such as Drupal core's, Laravel's or actix's awc counts). Exhaustive, deterministic.

  • `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout. (×8) — app/src/main/assets/webrequests/js/page-state-bridge.js:1473, app/src/main/assets/youtube/background.js:60, app/src/main/assets/youtube/background.js:528, …
  • `new OkHttpClient.Builder(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout. — app/src/main/java/com/solarized/firedown/sync/ServerTrust.java:99
  • `new OkHttpClient(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout. — app/src/main/java/com/solarized/firedown/sync/ServerTrust.java:110

What to do

  • Bound every outbound call: pass `signal: AbortSignal.timeout(ms)` to `fetch`, set `timeout` on the axios instance (`axios.create({ timeout })`), and add retries with back-off (`axios-retry`, `p-retry`) and a breaker (`opossum`, `cockatiel`) around dependencies that fail.
  • Set connect and read timeouts on every client (`RestTemplateBuilder.connectTimeout/readTimeout`, WebClient `responseTimeout`, `HttpRequest.Builder.timeout`, `HttpURLConnection.setReadTimeout`, Feign `connectTimeout`/`readTimeout` in configuration), and wrap calls to dependencies in resilience4j `@Retry`/`@CircuitBreaker`/`@TimeLimiter` (or Spring Retry).
PF3 · Async & latency hygiene6.0 / 10Adequate✓ Tool-verified

Readiness · Performance — Whether asynchronous code stays responsive — it avoids sync-over-async blocking (a .NET .Wait()/.GetAwaiter().GetResult(), a time.sleep or blocking HTTP call inside a Python coroutine, a *Sync call inside an async JavaScript function, block_on inside a Rust async fn, runBlocking inside a Kotlin suspend function, block() inside a Reactor publisher) that stalls a thread or event loop and risks deadlock, and, where the code is a reusable library on .NET, awaits with ConfigureAwait(false) so it never captures and stalls its caller's context.

Method: Production-source scan: sync-over-async blocking counted everywhere — .Wait()/.GetAwaiter().GetResult() in .NET; off .NET, read from each language's code model, a blocking call inside an async function (Python, TS/JS, Rust, Kotlin, Swift, Dart) or inside a Java method returning a Reactor Mono/Flux or a Scala method returning a Future or effect — and, for a .NET library with ≥5 awaits, the share of awaits using ConfigureAwait(false). Deterministic, syntax/text detection.

  • `readFileSync` in `fetch` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — scripts/consent-harness.mjs:70
  • `existsSync` in `find` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. (×2) — scripts/load-playwright.mjs:65, scripts/load-playwright.mjs:71

What to do

  • TypeScript/JavaScript: use the promise APIs (fs/promises, a promisified child_process.execFile, the async zlib/crypto functions) and await them instead of the *Sync variants.
R1 · Type Safety0.0 / 10Critical✓ Tool-verified

React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.

Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.

  • 0 typed · 24 plain JS — the untyped files are REDACTED, scripts/consent-harness.mjs, scripts/consent-smoke.mjs, scripts/dailymotion-replay.mjs, scripts/device-audit/judge.mjs, scripts/device-audit/selftest.mjs (+18 more).

What to do

  • Adopt TypeScript for the frontend: add a typecheck step to the build, then either type-check the existing JavaScript in place (`checkJs`/JSDoc types) or convert the highest-traffic modules first — no file is typed today, so this is an adoption, not a clean-up.
R10 · Code Duplication6.5 / 10Adequate✓ Tool-verified

React / JS · Code Health — The share of the scored frontend lines inside a near-exact copy-pasted block of substantial extent (the D4 clone algorithm over JS/TS tokens, D-386; each line once, 10 at none and 0 at a quarter of the lines, as D4): a block is reported only where its copies still agree on most of their own identifiers and literals, or were renamed as they were pasted but kept most of their constants, and where the copies carry enough code to stand on their own or the copied extent reaches 30 lines — so a re-implementation sharing neither names nor values, and a small pasted declaration, are both found and deliberately not reported, and a clean R10 is not a claim that nothing was copied.

Method: Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm run over JS/TS tokens). Masking finds the candidates; a block is reported when its copies still agree on most of their own identifiers and literals, or when a renamed copy still agrees on most of its constants, AND the copies carry enough code to stand on their own — or when the copied extent reaches 30 lines. So a re-implementation sharing neither names nor values, and a small pasted declaration, are deliberately not counted. Scored on the share of the scored frontend lines inside a reported copy, on the same curve as D4. Deterministic.

  • scripts/live-canary.mjs:44 · REDACTED:20 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — scripts/live-canary.mjs:44
  • scripts/dailymotion-replay.mjs:138 · scripts/instagram-replay.mjs:80 — the two spans are one implementation copied and then locally edited — 453 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — scripts/dailymotion-replay.mjs:138
  • REDACTED:38 · REDACTED:18 — the two spans are one implementation copied and then locally edited — 266 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — REDACTED:38
  • scripts/dailymotion-replay.mjs:34 · scripts/live-canary.mjs:44 · REDACTED:20 — the 3 copies are spread across 3 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — scripts/dailymotion-replay.mjs:34
  • scripts/live-canary.mjs:102 · REDACTED:218 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/live-canary.mjs:102
  • scripts/youtube-solver-smoke.mjs:33 · scripts/youtube-token-smoke.mjs:31 — the two spans are one implementation copied and then locally edited — 234 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — scripts/youtube-solver-smoke.mjs:33
  • REDACTED:35 · REDACTED:42 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:35
  • scripts/icons-smoke.mjs:17 · scripts/p2pshare-smoke.mjs:16 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it. — scripts/icons-smoke.mjs:17
  • scripts/instagram-replay.mjs:182 · scripts/instagram-replay.mjs:270 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/instagram-replay.mjs:182
  • scripts/har-wire-replay.mjs:155 · REDACTED:37 · REDACTED:44 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/har-wire-replay.mjs:155
  • scripts/consent-harness.mjs:48 · scripts/consent-smoke.mjs:26 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/consent-harness.mjs:48
  • REDACTED:44 · REDACTED:26 — the two spans are one implementation copied and then locally edited — 51 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — REDACTED:44
  • scripts/p2pshare-smoke.mjs:405 · scripts/p2pshare-smoke.mjs:418 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/p2pshare-smoke.mjs:405
  • scripts/p2pshare-smoke.mjs:585 · scripts/p2pshare-smoke.mjs:597 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/p2pshare-smoke.mjs:585
  • REDACTED:1760 · REDACTED:1769 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1760
  • scripts/dailymotion-replay.mjs:258 · scripts/dailymotion-replay.mjs:298 · scripts/instagram-replay.mjs:189 · scripts/instagram-replay.mjs:278 — the 4 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/dailymotion-replay.mjs:258
  • REDACTED:1206 · REDACTED:1214 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1206
  • scripts/p2pshare-smoke.mjs:653 · scripts/p2pshare-smoke.mjs:671 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/p2pshare-smoke.mjs:653
  • REDACTED:2252 · REDACTED:2592 — all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — REDACTED:2252
  • REDACTED:2545 · REDACTED:2559 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:2545
  • scripts/youtube-pip-smoke.mjs:138 · scripts/youtube-webcompat-smoke.mjs:212 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/youtube-pip-smoke.mjs:138
  • REDACTED:274 · REDACTED:792 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:274
  • scripts/dailymotion-replay.mjs:226 · scripts/dailymotion-replay.mjs:261 · scripts/dailymotion-replay.mjs:329 — all 3 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/dailymotion-replay.mjs:226
  • scripts/p2pshare-smoke.mjs:105 · scripts/p2pshare-smoke.mjs:118 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/p2pshare-smoke.mjs:105
  • REDACTED:1049 · REDACTED:1101 · REDACTED:1647 · REDACTED:2015 — all 4 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1049
  • REDACTED:1649 · REDACTED:1846 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1649
  • REDACTED:1260 · REDACTED:1279 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1260
  • REDACTED:2519 · REDACTED:2545 · REDACTED:2559 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. — REDACTED:2519
  • scripts/dailymotion-replay.mjs:72 · scripts/live-canary.mjs:81 · REDACTED:56 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — scripts/dailymotion-replay.mjs:72
  • REDACTED:1372 · REDACTED:1443 · REDACTED:1510 · REDACTED:1520 · +6 more site(s) not listed — all 10 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1372
  • REDACTED:1602 · REDACTED:1668 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1602
  • REDACTED:1651 · REDACTED:1670 · REDACTED:1811 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. — REDACTED:1651
  • REDACTED:1660 · REDACTED:1745 · REDACTED:1878 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. — REDACTED:1660
  • REDACTED:808 · REDACTED:982 · REDACTED:1024 · REDACTED:1682 — all 4 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:808
  • REDACTED:1526 · REDACTED:1539 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1526
  • REDACTED:1787 · REDACTED:1908 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — REDACTED:1787
  • REDACTED:972 · REDACTED:1718 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:972
  • REDACTED:1052 · REDACTED:1065 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1052
  • REDACTED:1249 · REDACTED:2510 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1249
  • REDACTED:1334 · REDACTED:1339 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — REDACTED:1334

What to do

  • Act on each finding's own remediation rather than one rule: the move depends on what recurs. Where the copies are executable blocks, give the shared part one home and call it from each site; where they are declarations, a listing, a specialisation already delegating to its base, or one shape repeated per entity, there is no call site and the move is a shared type, a generated set or a factory — sometimes there is nothing to extract.
R2 · Cyclomatic Complexity9.7 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Per-function cyclomatic/cognitive complexity from the token-level function scanner (D-386) — real branching, not a regex heuristic.

Method: Per-function cyclomatic/cognitive complexity from a token-level function scanner (real branching, not a regex heuristic), computed over every frontend function. Deterministic.

  • judgeSite has cyclomatic complexity 108 and cognitive complexity 163; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/device-audit/judge.mjs:162
  • formatSite has cyclomatic complexity 29 and cognitive complexity 49; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/device-audit/judge.mjs:360
  • (anonymous) has cyclomatic complexity 27 and cognitive complexity 47; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — signaling/server.js:146
  • fetch has cyclomatic complexity 19 and cognitive complexity 27; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — REDACTED:135
  • main has cyclomatic complexity 18 and cognitive complexity 26; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/device-audit/judge.mjs:417
  • suite has cyclomatic complexity 15 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/youtube-webcompat-smoke.mjs:96
  • candidateNames has cyclomatic complexity 14 and cognitive complexity 24; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/device-audit/judge.mjs:133
  • fetch has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — scripts/dailymotion-replay.mjs:106
R3 · Large Files10.0 / 10Exemplary✓ Tool-verified

React / JS · Code Health — How many source files exceed the large-file threshold.

Method: Components/modules exceeding the large-file threshold, counted exhaustively across the frontend source tree. Deterministic.

R4 · Test Coverage0.0 / 10Critical✓ Tool-verified

React / JS · Readiness — Static test reachability (D-386): the share of production files reachable from any test via the import graph — measured without running anything.

Method: Static test reachability: the share of production files reachable from any test via the import graph — measured without running anything. Deterministic.

  • 0% of 1 production file(s) reachable from 0 test file(s) via the import graph — 'production' here is the RESIDUE: every source file left once tests, tooling, generated output, config, declarations and declaration-only modules, fixture corpora, type fixtures, behaviour-free data modules, re-export barrels, registration/constant data modules and service workers are set aside, so the percentage is taken over a smaller denominator than the workspace's file count

What to do

  • Add tests that import the unreached modules (directly or through their public entry).
R7 · Dead Code9.5 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).

Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.

  • Unreachable from the 22 application, 4 tooling and 0 test entry point(s) detected in this repo. This repository declares no build, type-check or test script, so nothing here would fail on a wrong deletion — confirm by hand that nothing loads each file (including by a path built at runtime) before removing it. An undetected custom entry would make these reachable.
  • no import path from any entry point (22 application, 4 tooling, 0 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make — scripts/live-canary.mjs
  • This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it. — scripts/device-audit/judge.mjs:38

What to do

  • Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
R9 · Circular Imports10.0 / 10Exemplary✓ Tool-verified

React / JS · Architecture — Import cycles in the module graph (D-386) — files that can only be understood and changed together.

Method: Import cycles in the module graph, detected exhaustively over JS/TS imports (the same cycle detection as the .NET coupling dimension). Deterministic.

X16 · Unfloored truncation loop10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a loop that shortens a string until it fits a length budget has a floor — one with none grinds the value down to the empty string, or past it into a negative-length `Substring`.

Method: Roslyn syntax + semantics: while/do loops whose body's only effect on a string is to drop its last character, checked for whether anything — a direct comparison on the length, a body guard, a break — bounds that length below. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `while`/`do` loop whose body’s one assignment to a value is `x = x.slice(0, -1)` or `x = x.slice|substring|substr(0, x.length - 1)`, driven by a condition that reads `x.length` only as a term of a larger expression — never compared directly, never tested for truthiness, and with no other read of `x` — and whose body has no `break`, `return`, `throw` or `if` naming `x`. Deterministic, provable per finding. Advisory.

X18 · Disposal-pattern correctness10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a type's disposal matches what it OWNS — releasing what it created, leaving alone what it was handed, and not declaring a finalizer for state that has nothing unmanaged to finalize.

Method: Roslyn syntax + semantics: every assignment to a disposable field is read to decide whether the type CREATED the value or was handed it, and the type's disposal is checked against that answer — an injected interface it disposes, a value it constructed and never releases, a finalizer on a type holding nothing unmanaged, and a disposable local whose every reference is a plain member read. A value handed to a container that disposes its contents (a parent control's `Controls` collection, a component `IContainer`) is released by that container and is not reported; generated code is out of population. On a repository with no .NET source the same ownership questions are read in JavaScript/TypeScript off the engine’s own token stream (test, vendored, generated and minified paths not): a class declaring `dispose()`, `[Symbol.dispose]()` or `[Symbol.asyncDispose]()` that disposes a field it was handed through a constructor parameter typed as a repository interface or resolved by a dependency-injection container; that assigns a field only ever from `new X(…)` of a disposable class and neither releases it anywhere in the class nor names it in its disposal member or a method that member calls, nor hands it to anything else; and a `const`/`let` local built from literals only whose every reference opens a statement operating on a non-release member of it. A class is disposable when every repository declaration of its name declares or inherits a disposal member, or when it is a documented library disposable (`vscode` EventEmitter, CancellationTokenSource and Disposable; three.js geometries, materials, textures, render targets, renderers, controls and composers). The finalizer arm has no JavaScript counterpart: a class cannot declare one. Dart is read for the owned-and-never-released arm: a Flutter `State` (or a class declaring `dispose()`/`close()`) whose library-private field is written only with direct creations of a framework controller, `FocusNode`, `StreamController` or periodic `Timer` (or a `.listen(…)` into a field declared `StreamSubscription`), which nothing in the class or its library releases (`dispose`/`close`/`cancel`) and which is never handed on except as a named argument. Ruby is read for the owned-and-never-released arm and the abandoned-local arm: a class declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose instance variable is written only with a blockless core descriptor creation (`File.open`/`new`, `Tempfile`, `Dir.open`, `IO.popen`, the `socket` and `openssl` socket classes) that no method of the class closes and that is never handed on (passed, returned, stored, exposed by `attr_reader`, delegated) — a class whose superclass or mixin lies outside the repository is not judged — and a blockless creation read through and dropped (`File.open(path).read`) or held in a local that is never closed, returned, passed or stored (a `&:read` block-pass, an `autoclose: false` borrow and a `fileno` hand-over are not abandonment). PHP is read for the same two arms: a class (not a trait, and not one using a trait) declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose `private` property (or a `final` class's `protected` one) is written only with a direct core `fopen`, `tmpfile`, `popen`, `proc_open`, `fsockopen`, `stream_socket_client`/`server` or `opendir` that nothing in the class closes (`fclose`, `pclose`, `closedir`, `unset`, a reset to `null`) and that is never handed on, and a handle held in a function's local, or read through as the argument of a reader, that is never closed, returned, passed, captured or stored; a `php://` stream, `curl_init`, `SplFileObject`, `PDO` and a function the repository declares under the core name are not read. Deterministic, provable per finding. Advisory.

X2 · Cancellation propagation6.6 / 10Adequate✓ Tool-verified

Other · Code Health — Whether async functions that make a cancellable request accept or pass on an AbortSignal (adoption curve).

Method: Roslyn scan: every async method (excluding framework-fixed overrides/Blazor handlers) checked for CancellationToken parameter presence. Deterministic, adoption percentage. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same question: every named async function that itself makes a request an AbortSignal can cancel (global `fetch`, axios and its file-local instances, ky, ofetch) counts, and it is compliant when its parameters or body name a signal or it hands one of its own parameters to the request as options; signatures a framework fixes (JSX event handlers, route and lifecycle exports, request-first handlers, `override`, `'use server'` modules, TanStack `mutationFn`) are exempt unless they take a signal. Deterministic, adoption percentage.

  • Only 10/23 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
  • `loadSolver` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/youtube/background.js:42
  • `fetchMainPlayer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/youtube/background.js:516
  • `fetchAndCachePlayer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/youtube/background.js:773
  • `processVideo` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/youtube/background.js:1975
  • `fetchMediaList` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/page-state-bridge.js:1470
  • `fetchKickChannel` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/kick.js:73
  • `fetchKickClip` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/kick.js:101
  • `fetchKickVideo` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/kick.js:141
  • `fetchTwitchLiveStream` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/twitch.js:229
  • `fetchTwitchVod` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/twitch.js:338
  • `fetchTwitchClip` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/webrequests/js/parsers/twitch.js:431
  • `verifyResumeTail` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/p2pshare/engine-page.js:737
  • `pumpFile` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — app/src/main/assets/p2pshare/engine-page.js:831

What to do

  • Thread an AbortSignal through async functions that make requests, so the work stops when its caller gives up.
X20 · Mistyped argument guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether an argument guard throws the exception its own condition describes — a guard that rejects a value for being EMPTY and reports it as `NullPointerException` (Java, Kotlin, Scala), `ArgumentError.notNull` (Dart) or `ArgumentNullException` (F#'s `nullArg`) tells the caller a parameter was null when it provably was not.

Method: Roslyn syntax: `throw new ArgumentNullException(nameof(p))` statements (or a repository exception type deriving from it) controlled by an `if` — directly or through the `using`, `lock` or `try` that wraps the throw — whose condition is read for a test that is true of a NON-null `p` — an emptiness test that dereferences it (`p.Count == 0`, `!p.Any()`) or a BCL predicate documented true of the empty value (`string.IsNullOrEmpty(p)`); in the `else` branch, for a conjunct of the admitting condition that is FALSE of a non-null `p`. Range guards are read for bounds that leave nothing and for a `p > C.Count` bound whose index then reaches `C[p]`, `C.RemoveAt(p)` or a method of the same type that indexes with it. Deterministic, provable per finding. Advisory.

X21 · Side-effecting pattern guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `when` guard is free of side effects — a guard that increments a counter or assigns while deciding whether its arm matches applies that change during PATTERN MATCHING, on an arm that may not be selected, and skips it entirely when a short-circuit to its left answers first.

Method: Roslyn syntax: `when` guards on case labels and switch-expression arms, read for a mutation (`++`/`--`/assignment) sitting in a position the guard's own `&&`/`||`/`??`/`?:`/`?.` can skip. Deterministic, provable per finding. Advisory.

X24 · Document value interpolated into markup unescaped4.8 / 10Weak✓ Tool-verified

Other · Security — Whether text read out of the document being converted is escaped before it is written into generated markup — a value the document's author chose, interpolated into an attribute the surrounding literal delimits, can close that attribute and open another.

Method: Roslyn semantic model over the whole compilation: a string-typed `Value`/`InnerText`/`InnerXml`/`Text` member declared inside `DocumentFormat.OpenXml` or `System.Xml` is a taint SOURCE, propagated through assignments, returns, arguments, tuple elements and string composition to its transitive closure, then read at interpolated-string holes that sit in a markup position the surrounding literal itself delimits. Escaper/encoder calls and enclosing validator conditions cut the flow. Flow- and container-insensitive by construction. A second arm needs no provenance at all and reports a type that CONTRADICTS ITSELF — the same expression escaped at one delimited markup hole and interpolated raw at another hole in the same markup position of the same type, which the type's own escaping proves is a defect without knowing where the value came from. On a repository with no .NET source it reads JavaScript/TypeScript off the token stream with the same rule: a DOM read of raw document text (`getAttribute`, `textContent`, `innerText`, `nodeValue`) is the source, propagated through local bindings and string composition, and judged at template-literal and concatenation holes in the same two delimited markup positions; escapers and validating conditions cut it, and documentation-site, test, vendored and minified scripts are not read. Deterministic, provable per finding. Advisory.

  • `id` is text this program did not author, and it is written into a URL attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — signaling/server.js:125

What to do

  • Each finding names the expression, the attribute it lands in and the line. Confirm the value's origin from the read this analyzer traced, then escape it at the sink or validate it against the shape the attribute accepts before interpolating.
X25 · Inert configuration knob10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a value the caller is invited to supply is the value the type actually uses — a constructor parameter stored in a private field that nothing ever reads while the default it was given is spelled out a second time at the site that should have read it, a keyed lookup that falls back to a different setting than the one its key names while the same type falls back to the matching one for that same key, or a culture-sensitive parse given no format provider by a type that feeds its own settable culture to the same kind of parse elsewhere, or a number an entry point writes to standard output under the host's culture while the same entry point formats with the invariant culture elsewhere. Either way, every caller who supplies a value silently gets something else.

Method: Roslyn syntax: private instance fields of a non-partial type assigned in a constructor from one of its own parameters with a `??` fallback, checked for whether anything in the type body reads the field and whether that same fallback expression is spelled out again outside the constructor; and `??` fallbacks onto a member access from a lookup call carrying exactly one string literal, grouped by that key across the type and checked for a fallback member whose folded name disagrees with the key while a sibling site for the same key agrees with it. On a repository with no .NET source the first two arms read JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `#x`, `private` or `private` parameter-property instance field filled in the constructor from a parameter (or one member of one) through `??`/`||` or a parameter default, never read anywhere in the file by name, whose constructed default is spelled again in the class body; and `lookup("key") ?? s.member` grouped by key per class, or per module outside every class. The culture arm has no JavaScript counterpart: its parses take no locale. Deterministic, provable per finding. Advisory.

X27 · Collection changed while being enumerated10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether an enhanced `for` leaves the collection it is walking alone — a body that adds to or removes from the very collection the loop is iterating invalidates the fail-fast iterator it is holding, so the next `next()` throws `ConcurrentModificationException` and the remaining elements are never seen.

Method: Roslyn syntax + semantics: `foreach` statements whose body calls a structural mutator (`Add`/`Remove`/`Clear`/`Insert`/…) on the very expression the loop is enumerating. Two arms. ARM A — the source is a concrete fragile BCL collection, or a live `Keys`/`Values` view over one, and the mutator resolves to that same collection's own member; concurrent and immutable collections and arrays are outside the population by construction, since their enumerators survive a structural change. ARM B — the source is an argument-less accessor CALL on a receiver whose body is in source: the accessor must return a stored field VERBATIM and a sibling member must structurally change that same field, both read off the implementations rather than from the members' names. A mutation the loop provably exits immediately after (`break`/`return`/`throw`/`goto`), or one written inside a nested loop or a lambda, is counted and never reported. Deterministic, provable per finding. Advisory.

X28 · Index access outside its own emptiness guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a condition that tests a value for emptiness indexes that same value only where the test holds — an `||` written one parenthesis too far to the left leaves an index access outside the guard beside it, so the empty case the guard exists to anticipate reaches the index and throws.

Method: Roslyn syntax only, no semantic model: the OUTERMOST `&&`/`||` of every boolean condition, read for a symbol the condition tests for emptiness (`string.IsNullOrEmpty`/`IsNullOrWhiteSpace`, a `Length`/`Count` comparison against a literal, `Any()`, a `Length`/`Count` pattern, or a comparison against `""`) and ALSO indexes. Each `symbol[...]` access is placed by a boolean-reachability walk from the access up to the outermost connective: an access is COVERED when some enclosing step has it in the right operand and the left operand, under the truth value that step forces, proves the symbol non-empty — a recursion over `&&`/`||` whose true- and false-directions are asymmetric. A finding needs BOTH an uncovered access and a covered one on the same symbol in the same condition, which is the agreeing twin that separates a misplaced parenthesis from an unrelated length test. Bare index accesses with no emptiness test in the condition are neither counted nor reported; a non-identifier receiver and a lambda nested inside the condition are outside the population. Deterministic, provable per finding. Advisory.

X29 · Per-element action decided by a fixed element10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a decision taken once per element is taken ABOUT that element — a test inside a counted loop that reads a fixed subscript of the very collection its guarded statement indexes by the loop variable applies element zero's answer to all of them, so the elements that differ from it are all handled wrongly, and in the same direction.

Method: Roslyn syntax only, no semantic model: every `for` statement declaring exactly ONE loop variable, and every `if` inside its body that is not under a nested loop or a lambda. A site enters the population when the `if`’s condition never mentions the loop variable while the statement it guards indexes some collection by that variable ALONE (`c[i]`; `c[i + 1]` and `c[i, j]` are outside it). A finding additionally needs the AGREEING TWIN at the same-collection grain: the condition must read THAT SAME collection at a subscript that does not move — written into the condition, or reached through a local declared BEFORE the loop, so an alias bound inside the body is not followed. Both collection expressions must be simple identifiers. On a repository with no .NET source the same rule reads JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `for (let|var|const x = …; …; …)` with one declarator and a braced body, an alias followed only when it is declared before the loop in a block that encloses it and never assigned inside the loop. Deterministic, provable per finding. Advisory.

X3 · Exception handling5.4 / 10Adequate✓ Tool-verified

Other · Code Health — Whether exceptions are handled rather than silently swallowed or rethrown with lost stack traces.

Method: Roslyn syntax scan: every catch clause counted; empty catches and bare rethrows flagged. Population is all catch clauses, not estimated. Deterministic, hard fact.

  • `catch (PackageManager.NameNotFoundException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — app/src/main/java/com/solarized/firedown/App.java:383
  • `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. (×16) — app/src/main/java/com/solarized/firedown/GlideHelper.java:920, app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:140, app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:174, …
  • `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. (×14) — app/src/main/java/com/solarized/firedown/UpdateInstallReceiver.java:150, app/src/main/java/com/solarized/firedown/UpdateNotification.java:158, app/src/main/java/com/solarized/firedown/utils/CaptureUrlActions.java:110, …
  • `catch (GeneralSecurityException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — app/src/main/java/com/solarized/firedown/sync/BackupLayout.java:260
  • `catch (IOException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. (×4) — app/src/main/java/com/solarized/firedown/sync/FolderStore.java:664, app/src/main/java/com/solarized/firedown/sync/S3Store.java:101, app/src/main/java/com/solarized/firedown/sync/WebDavStore.java:76, …
  • An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it. (×4) — app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:390, app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:407, app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:503, …

What to do

  • Swallowed exception (caught, then discarded)
X30 · Support guard that admits what it rejects10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a guard written as a NEGATED `||` says what its author meant — `!(a || b || x != k)` is `!a && !b && x == k` by De Morgan, so a bail-out that mixes capabilities the code needs with a fault it refuses turns inside out: it fires only where the capabilities are ABSENT, and lets every value the fault term names walk straight into the body that cannot handle it.

Method: Roslyn syntax only, no semantic model: every logical-not whose operand is a parenthesised `||` chain of two or more disjuncts, flattened (a left-nested `a || b || c` read once would see `(a || b)` as one disjunct). A site enters the population on that shape alone. A finding additionally needs the disjuncts to DISAGREE in polarity: at least one bare boolean read — an identifier or member access, never an invocation, which is a predicate rather than a capability flag — and at least one `x != <constant>`, the only form that negates into an exact-value pin (`== null` negates into a looser requirement and is outside the fault set). Consistently-polarised disjunctions, all-fault or all-capability, are counted and never reported; a negated `&&` is outside the population entirely. No same-receiver gate: it was measured to cost a real defect and remove no false positive. Deterministic, provable per finding. Advisory.

X5 · Nullable reference types2.0 / 10Critical✓ Tool-verified

Other · Code Health — Whether Java packages are null-marked and not undermined by heavy nullness suppression — a package under `@NullMarked` (or `@NonNullApi`, `@ParametersAreNonnullByDefault`, `@NonNullByDefault`, or a NullAway/Checker Framework configuration naming it) makes an unannotated reference exclude null, and `@SuppressWarnings("NullAway")`, `("nullness")`, `("null")` and `castToNonNull(…)` are what silence it.

Method: Roslyn compiler-options scan: NullableContextOptions per project; null-forgiving (!) suppression density per 1k syntax nodes. Deterministic, adoption plus suppression penalty.

  • 0/45 of this repository's Java package directories are under a non-null default: a `package-info.java` declaring `@NullMarked` (JSpecify) or `@NonNullApi`, `@ParametersAreNonnullByDefault`, `@NonNullByDefault`, `@DefaultQualifier(NonNull.class)`; a `module-info.java` declaring `@NullMarked`; every type in it `@NullMarked`; or a build that runs NullAway with the package in `AnnotatedPackages`, or the Checker Framework's `NullnessChecker`. Elsewhere every reference admits null and no checker warns on the dereference that throws a `NullPointerException`.

What to do

  • Declare the default where Java declares it: `@NullMarked` (org.jspecify.annotations) in each package's `package-info.java`, or once in `module-info.java`, and run NullAway (Error Prone) or the Checker Framework so the declaration is enforced. Then annotate the real exceptions `@Nullable` and resolve the suppressions rather than adding to them: a `@SuppressWarnings("NullAway")` or `castToNonNull(x)` on a value the checker could show to be null is a `NullPointerException` waiting for the path that makes it true — where the value genuinely cannot be null, say something the checker can see instead (a null check, `Objects.requireNonNull`, a non-null field initialised in the constructor).

WCAG coverage — what static analysis assessed

Statically assessed 15 of 55 WCAG 2.2 Level A/AA success criteria (27%; ≈30% of the 50 WCAG 2.1 AA criteria for EN 301 549). The other 40 require runtime or manual evaluation. Partial signal only (a clean result is necessary, not sufficient; static analysis fully verifies none). This is accessibility readiness, not a conformance claim — a WCAG conformance claim requires manual evaluation (WCAG-EM 1.0).

DimensionWCAG 2.2 A/AA criteriaCoverage
AC1 · Text alternatives1.1.1, 1.2.2, 1.2.5Partial signal
AC2 · Forms & labels1.3.1, 3.3.2, 4.1.2Partial signal
AC3 · Page structure1.4.4, 2.2.1, 2.4.1, 2.4.2, 3.1.1, 4.1.2Partial signal
AC4 · Keyboard semantics2.1.1, 2.4.3Partial signal
AC6 · Visual & motion safety1.4.3, 2.4.7Partial — literal CSS only

Not statically assessed — these 40 Level A/AA criteria need runtime or manual evaluation (WCAG-EM): 1.2.1, 1.2.3, 1.2.4, 1.3.2, 1.3.3, 1.3.4, 1.3.5, 1.4.1, 1.4.2, 1.4.5, 1.4.10, 1.4.11, 1.4.12, 1.4.13, 2.1.2, 2.1.4, 2.2.2, 2.3.1, 2.4.4, 2.4.5, 2.4.6, 2.4.11, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.7, 2.5.8, 3.1.2, 3.2.1, 3.2.2, 3.2.3, 3.2.4, 3.2.6, 3.3.1, 3.3.3, 3.3.4, 3.3.7, 3.3.8, 4.1.3.

Reference — by lens

The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.

LensScoreRatingImpact
Code Health42.0Weak — gated by D2, R1, X5Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Architecture76.3Adequate — gated by D26Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Maturity54.0Adequate — gated by M2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Readiness15.0Critical — gated by D13, R4, P1, P2, P3, P7Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Security72.8Checked 4 of 10Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Accessibility27.5Weak — gated by AC1, AC4Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Performance60.0AdequateStrongest area.
Unscored — 3 check(s) recorded observations but carry no score

These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.

  • X10 Duplicated predicate — 40 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X6 Hand-rolled structured-format parsing — 9 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X7 Silent fallback defaults — 38 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 4 control(s) we could not find positive evidence for

These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.

  • C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • P4 Deployment & Rollback — not evidenced — no deploy/rollback/approval signal in the repo; absence of evidence is not evidence of a manual release
Not included — 55 check(s) not relevant to this codebase

These checks had nothing to measure here (no tests, no git history, the codebase is small, or the architecture style doesn't apply), so they're omitted above rather than scored low.

  • AC5 ARIA correctness — No ARIA usage found in the parsed markup — AC5 not applicable here.
  • AX1 Captive dependencies — Not applicable: Dagger rejects, at compile time, a component that holds a binding with a narrower scope than its own.
  • AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AX8 Test isolation — no test/production split to check
  • AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
  • AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • AXR1 Runtime accessibility — the Android app did not build — `./gradlew :app:assembleDebug` exited 1: 054c86ad767ee62f25bc59/settings.gradle' line: 55 * What went wrong: A problem occurred evaluating settings '.'. > scripts/fetch-prebuilts.sh failed (exit…; runtime evidence skipped (launch chosen because app/build.gradle applies the Android application plugin and gradlew builds it) This is a statement about this run, not a statement about your application: nothing here says the app is inaccessible, only that it was never run.
  • C1 Data Protection — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • D11 Test Reliability — Test reliability not included — the .java suite was found but not re-run
  • D12 Dependency Hygiene — Not scored — 2 Maven/Gradle manifest(s) were read, stating a version for 41 dependency(ies) and leaving 2 to a parent or an imported BOM, but no build resolved the dependency graph, so the outdated signal was not established. NOT a finding that these dependencies are current or healthy.
  • D16 Bus Factor — single-maintainer repository — bus factor is not applicable
  • D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
  • D22 Internal API Consistency — The exposed public-API surface could not be collected — no C#/VB projects loaded.
  • D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ sibling projects each declaring an entity of their own or taking another project's integration events. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
  • D25 ADR Conformance — no ADRs to check
  • D30 Dependency Vulnerabilities — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Gradle build (build.gradle/build.gradle.kts) — not scanned yet).
  • D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
  • D32 Data Compliance (PII/GDPR) — 1 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
  • D36 Supply-chain Provenance & Signing — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for.
  • D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
  • D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
  • D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
  • D43 Malicious Dependencies — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Gradle build (build.gradle/build.gradle.kts) — not scanned yet).
  • D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
  • D8 Code Coverage — Coverage not included — suite not readable by the collector
  • DM1 Domain Modelling — applicable but not scored (2 of 3 signals for this style — below the bar we score at): 62 value object(s); 5 repository port(s) loading or saving an aggregate/entity
  • ED1 Event-Driven — not scored — this repository shows none of the 3 signals this lens looks for
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
  • M4 Documentation accuracy — Not applicable: the 6 current-state document(s) make no claim of a kind M4 checks. 45 claim(s) of kinds M4 does not check were not checked (path 25, command argument 6, environment variable 12, route 2); M4 checks only links and versions and artefact counts.
  • P12 CI test-gate honesty — no CI workflow found
  • P8 Schema migrations — no ORM, schema-migration tool or schema auto-create was found in this repository's dependency manifests or source, so there is no database schema for this check to judge
  • P9 Domain vs controller coverage — coverage not measured: this check compares the coverage of the analyzer's own test run across the domain and web layers, and that run measured none here — Test coverage (D8) says why
  • PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for `@Benchmark` in a Java, Kotlin or Scala file importing JMH or kotlinx-benchmark, Jetpack Benchmark's `measureRepeated` in a file importing androidx.benchmark, or JMH/kotlinx-benchmark/androidx.benchmark in a pom.xml, Gradle or sbt build, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
  • PF2 Allocation hygiene — Not scored: this check counted allocation-aware idioms (Span, pools, stackalloc) per line, which describes what kind of code a repository is rather than whether it has an allocation problem, so it was withdrawn. Nothing here is a finding about your code.
  • R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
  • R5 Dependency Freshness — no package-lock.json — dependency freshness not measured (would require an npm lockfile); JS/npm CVEs are scored in D30 (Dependency Vulnerabilities), which answers every ecosystem
  • R6 Tooling — no package.json in the repository — test/lint/typecheck wiring is read from package.json scripts (corroborated against CI), so this project's own toolchain isn't measured here
  • R8 Dependency Hygiene — Not measured — no package.json declares any dependency, so there is nothing to check imports against (imports may resolve through a host runtime rather than node).
  • S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
  • X1 Async correctness — X1 reached only 19% of this repository's production lines — java (162,929 lines), c (8,731 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
  • X12 Unreachable branch — X12 reached only 19% of this repository's production lines — java (162,929 lines), c (8,731 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
  • X13 Undrained process stream — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X14 Bypassable address classification — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X15 Unvalidated length from an untrusted reader — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X17 Uncapped recursion over a caller-supplied document — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X19 Unrestored process-global state — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X22 Contradicted release guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X23 Unguarded diagnostic materialisation — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X26 Unsynchronised callback handoff — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
  • X4 Structured logging — This check asks whether log calls keep a message's values apart from its text, which needs a logger that can carry them as fields. This repository's Java was read, and it logs through none that an assembled message defeats: java.util.logging's level methods, log4j 1, commons-logging, JBoss Logging and Flogger take one finished message (as log4net does in C#), or it makes no call through a named logger at all. Calls made through SLF4J or log4j 2 (`org.slf4j.Logger`, `org.apache.logging.log4j.Logger`, Lombok's `@Slf4j`) would be judged.
  • X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.

Appendix A — Findings (grouped)

The findings behind the scores, grouped by severity, then by dimension and kind. The high-severity issues are enumerated in full below; items per group are capped at 25 with any overflow stated explicitly per group, never silently truncated. The complete machine-readable list of every finding (all severities) is the companion findings.md in this report's bundle.

Critical — 33 finding(s)
AC2 · Forms & labels · <input> without a programmatic label · ×7
  • <input> without a programmatic label sketches/bookmark-edit-improvements.html:514 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label sketches/bookmark-edit-improvements.html:518 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label sketches/browsesubtitlegrouping.html:592 — This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
  • <input> without a programmatic label sketches/home-ember-tuner.html:98 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label sketches/home-ember-tuner.html:99 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label sketches/home-ember-tuner.html:100 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label sketches/home-slickness-directions.html:104 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
D13 · REDACTED Scanning · Leaked secret · ×5
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
AC3 · Page structure · <html> without a lang · ×4
  • <html> without a lang design/home-incognito-illus.html:1 — The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
  • <html> without a lang design/inc_landscape.html:1 — The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
  • <html> without a lang design/pills_card.html:1 — The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
  • <html> without a lang sketches/active-download-card.html:1 — The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
AC3 · Page structure · Document without a <title> · ×3
  • Document without a <title> design/home-incognito-illus.html:1 — A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>.
  • Document without a <title> design/inc_landscape.html:1 — A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>.
  • Document without a <title> design/pills_card.html:1 — A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
AC1 · Text alternatives · <img> without a text alternative · ×2
  • <img> without a text alternative design/home-incognito-illus.html:20 — An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
  • <img> without a text alternative design/inc_landscape.html:16 — An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
AC2 · Forms & labels · <label> that labels no control · ×2
  • <label> that labels no control sketches/bookmark-edit-improvements.html:513 — This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
  • <label> that labels no control sketches/bookmark-edit-improvements.html:517 — This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
D28 · Secrets (history) · REDACTED · ×1
  • REDACTED
Serious — 1410 finding(s)
D15 · Churn × Complexity Hotspots · Hotspot · ×67
  • Hotspot: app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java changed 59 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 100 in BrowserFragment.onViewCreated at line 736. 10 of those changes were fix/bug commits, and the other 49 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/requests.js app/src/main/assets/webrequests/js/requests.js:1027 — app/src/main/assets/webrequests/js/requests.js changed 38 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 87 in requests.emitCapture at line 1027. 4 of those changes were fix/bug commits, and the other 34 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/requests.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/page-state-bridge.js app/src/main/assets/webrequests/js/page-state-bridge.js:1266 — app/src/main/assets/webrequests/js/page-state-bridge.js changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 108 in page-state-bridge.collectPlayableMedia at line 1266. 5 of those changes were fix/bug commits, and the other 10 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/page-state-bridge.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/youtube/background.js app/src/main/assets/youtube/background.js:1975 — app/src/main/assets/youtube/background.js changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 133 in background.processVideo at line 1975. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/youtube/background.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/content-script.js app/src/main/assets/webrequests/js/content-script.js:3825 — app/src/main/assets/webrequests/js/content-script.js changed 29 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in content-script.scrapeInlineScripts at line 3825. 5 of those changes were fix/bug commits, and the other 24 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/content-script.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:164 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 81 in EngineHarness.run at line 164. 1 of those changes was a fix/bug commit, and the other 8 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/capture-harness/src/com/solarized/firedown/harness/CaptureHarness.java scripts/capture-harness/src/com/solarized/firedown/harness/CaptureHarness.java:364 — scripts/capture-harness/src/com/solarized/firedown/harness/CaptureHarness.java changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in CaptureHarness.main at line 364. 1 of those changes was a fix/bug commit, and the other 13 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- scripts/capture-harness/src/com/solarized/firedown/harness/CaptureHarness.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:110 — app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 34 in SettingsActivity.onCreate at line 110. 1 of those changes was a fix/bug commit, and the other 16 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: REDACTED REDACTED:135 — REDACTED changed 25 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in parsers-replay.fetch at line 135. 4 of those changes were fix/bug commits, and the other 21 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- REDACTED`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:811 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in DownloadItemAdapter.bindFull at line 811. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:485 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in BaseDownloadFragment.handleOptionSelection at line 485. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/parsers/tiktok.js app/src/main/assets/webrequests/js/parsers/tiktok.js:305 — app/src/main/assets/webrequests/js/parsers/tiktok.js changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 61 in tiktok.handleTikTokItemList at line 305. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/parsers/tiktok.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/device-audit/judge.mjs scripts/device-audit/judge.mjs:162 — scripts/device-audit/judge.mjs changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 128 in judge.judgeSite at line 162. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- scripts/device-audit/judge.mjs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 27 in HomeFragment.onViewCreated at line 290. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:407 — app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in SettingsFragment.onSharedPreferenceChanged at line 407. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/update-install-test/fake_adb.py scripts/update-install-test/fake_adb.py:335 — scripts/update-install-test/fake_adb.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 67 in fake_adb.shell at line 335. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- scripts/update-install-test/fake_adb.py`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/parsers/common.js app/src/main/assets/webrequests/js/parsers/common.js:191 — app/src/main/assets/webrequests/js/parsers/common.js changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in common.sendVariants at line 191. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/parsers/common.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/BaseActivity.java app/src/main/java/com/solarized/firedown/BaseActivity.java:355 — app/src/main/java/com/solarized/firedown/BaseActivity.java changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in BaseActivity.addonEventText at line 355. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/BaseActivity.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:132 — app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java changed 20 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in SecurityStateSheetDialogFragment.onCreateView at line 132. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/addons/AddonManager.java app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1445 — app/src/main/java/com/solarized/firedown/addons/AddonManager.java changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in AddonManager.checkForUpdates at line 1445. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/addons/AddonManager.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/parsers/page-state.js app/src/main/assets/webrequests/js/parsers/page-state.js:303 — app/src/main/assets/webrequests/js/parsers/page-state.js changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in page-state.handlePageStateHls at line 303. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/parsers/page-state.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/GlideHelper.java app/src/main/java/com/solarized/firedown/GlideHelper.java:967 — app/src/main/java/com/solarized/firedown/GlideHelper.java changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in GlideHelper.load at line 967. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/GlideHelper.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/assets/webrequests/js/snapshot.js app/src/main/assets/webrequests/js/snapshot.js:832 — app/src/main/assets/webrequests/js/snapshot.js changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 45 in syncDynamicState at line 832. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/assets/webrequests/js/snapshot.js`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:260 — app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 35 in VaultBackupWorker.doWork at line 260. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:125 — app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in SabrStrategy.executeInternal at line 125. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • + 42 more in this group — see findings.md.
D3 · God Classes · TooManyMethods · ×48
  • TooManyMethods: BrowserFragment app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:136 — TooManyMethods — 140 methods. The bar is 30 methods; this is 110 over it, 4.67× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: GeckoState app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:39 — TooManyMethods — 128 methods. The bar is 30 methods; this is 98 over it, 4.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: AddonManager app/src/main/java/com/solarized/firedown/addons/AddonManager.java:88 — TooManyMethods — 100 methods. The bar is 30 methods; this is 70 over it, 3.33× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: BrowserDownloadEntity app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java:28 — TooManyMethods — 92 methods. The bar is 30 methods; this is 62 over it, 3.07× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: P2pShareController app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:123 — TooManyMethods — 89 methods. The bar is 30 methods; this is 59 over it, 2.97× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: MediaViewerFragment app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:129 — TooManyMethods — 73 methods. The bar is 30 methods; this is 43 over it, 2.43× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: GeckoInspectEntity app/src/main/java/com/solarized/firedown/data/entity/GeckoInspectEntity.java:6 — TooManyMethods — 68 methods. The bar is 30 methods; this is 38 over it, 2.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: BaseBrowserFragment app/src/main/java/com/solarized/firedown/phone/fragments/BaseBrowserFragment.java:51 — TooManyMethods — 61 methods. The bar is 30 methods; this is 31 over it, 2.03× the bar. Most of these members implement geckoview.GeckoObserver (45 of 61 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member.
  • TooManyMethods: DownloadEntity app/src/main/java/com/solarized/firedown/data/entity/DownloadEntity.java:38 — TooManyMethods — 59 methods. The bar is 30 methods; this is 29 over it, 1.97× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: GeckoStateEntity app/src/main/java/com/solarized/firedown/data/entity/GeckoStateEntity.java:15 — TooManyMethods — 57 methods. The bar is 30 methods; this is 27 over it, 1.90× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: BaseDownloadFragment app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:89 — TooManyMethods — 56 methods. The bar is 30 methods; this is 26 over it, 1.87× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: BrowserOptionAdapter app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:74 — TooManyMethods — 56 methods. The bar is 30 methods; this is 26 over it, 1.87× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: CloudBackupListFragment app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:94 — TooManyMethods — 55 methods. The bar is 30 methods; this is 25 over it, 1.83× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: DownloadItemAdapter app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:62 — TooManyMethods — 55 methods. The bar is 30 methods; this is 25 over it, 1.83× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: UpdateDownloader app/src/main/java/com/solarized/firedown/UpdateDownloader.java:52 — TooManyMethods — 54 methods. The bar is 30 methods; this is 24 over it, 1.80× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: FileUriHelper app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:27 — TooManyMethods — 51 methods. The bar is 30 methods; this is 21 over it, 1.70× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: FFmpegEntity app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:10 — TooManyMethods — 50 methods. The bar is 30 methods; this is 20 over it, 1.67× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: GeckoToolbar app/src/main/java/com/solarized/firedown/geckoview/GeckoToolbar.java:35 — TooManyMethods — 46 methods. The bar is 30 methods; this is 16 over it, 1.53× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: DownloadRequest app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:24 — TooManyMethods — 46 methods. The bar is 30 methods; this is 16 over it, 1.53× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: DownloadTask app/src/main/java/com/solarized/firedown/manager/DownloadTask.java:45 — TooManyMethods — 46 methods. The bar is 30 methods; this is 16 over it, 1.53× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: Utils app/src/main/java/com/solarized/firedown/utils/Utils.java:59 — TooManyMethods — 46 methods. The bar is 30 methods; this is 16 over it, 1.53× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: DownloadFragment app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:84 — TooManyMethods — 45 methods. The bar is 30 methods; this is 15 over it, 1.50× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: S3Client REDACTED:86 — TooManyMethods — 45 methods. The bar is 30 methods; this is 15 over it, 1.50× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: SyncSettingsFragment app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:102 — TooManyMethods — 44 methods. The bar is 30 methods; this is 14 over it, 1.47× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: GlideHelper app/src/main/java/com/solarized/firedown/GlideHelper.java:59 — TooManyMethods — 43 methods. The bar is 30 methods; this is 13 over it, 1.43× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • + 23 more in this group — see findings.md.
X3 · Exception handling · Swallowed exception (caught, then discarded) · ×36
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/App.java:383 — `catch (PackageManager.NameNotFoundException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/GlideHelper.java:920 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/UpdateInstallReceiver.java:150 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/UpdateNotification.java:158 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/CaptureUrlActions.java:110 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/ClipboardHelper.java:83 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:140 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:174 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:323 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/utils/QrCodes.java:168 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/ui/adapters/MostVisitedTilesAdapter.java:115 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/BackupLayout.java:260 — `catch (GeneralSecurityException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:687 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:385 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:498 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:613 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:664 — `catch (IOException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) REDACTED:1203 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) REDACTED:1215 — `catch (RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/S3Store.java:101 — `catch (IOException | RuntimeException)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/SyncManager.java:201 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/SyncManager.java:263 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/SyncManager.java:299 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/SyncManager.java:345 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) app/src/main/java/com/solarized/firedown/sync/SyncSecrets.java:98 — `catch (Exception)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • + 11 more in this group — see findings.md.
D3 · God Classes · FileTooLong · ×28
  • FileTooLong: fragments/BrowserFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java — FileTooLong — 2227 significant lines (blank, comment-only and punctuation-only lines excluded), about 94% of them inside a single declaration: BrowserFragment (136-4263). The bar is 500 significant lines; this is 1727 over it, 4.45× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: addons/AddonManager.java app/src/main/java/com/solarized/firedown/addons/AddonManager.java — FileTooLong — 1400 significant lines (blank, comment-only and punctuation-only lines excluded), about 96% of them inside a single declaration: AddonManager (88-2275). The bar is 500 significant lines; this is 900 over it, 2.80× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: p2pshare/P2pShareController.java app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java — FileTooLong — 1328 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 828 over it, 2.66× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: fragments/MediaViewerFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java — FileTooLong — 1290 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: MediaViewerFragment (129-2556). The bar is 500 significant lines; this is 790 over it, 2.58× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: geckoview/GeckoComponents.java app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java — FileTooLong — 1175 significant lines (blank, comment-only and punctuation-only lines excluded), about 94% of them inside a single declaration: GeckoComponents (79-2312). The bar is 500 significant lines; this is 675 over it, 2.35× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: settings/CloudBackupListFragment.java app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java — FileTooLong — 857 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: CloudBackupListFragment (94-1728). The bar is 500 significant lines; this is 357 over it, 1.71× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: geckoview/GeckoRuntimeHelper.java app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java — FileTooLong — 850 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 350 over it, 1.70× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: fragments/BaseDownloadFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java — FileTooLong — 835 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: BaseDownloadFragment (89-1494). The bar is 500 significant lines; this is 335 over it, 1.67× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: adapters/DownloadItemAdapter.java app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java — FileTooLong — 812 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: DownloadItemAdapter (62-1744). The bar is 500 significant lines; this is 312 over it, 1.62× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: adapters/BrowserOptionAdapter.java app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java — FileTooLong — 790 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: BrowserOptionAdapter (74-1327). The bar is 500 significant lines; this is 290 over it, 1.58× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: REDACTED REDACTED — FileTooLong — 784 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: S3Client (86-1279). The bar is 500 significant lines; this is 284 over it, 1.57× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: utils/FileUriHelper.java app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java — FileTooLong — 730 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 230 over it, 1.46× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: settings/SyncSettingsFragment.java app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java — FileTooLong — 670 significant lines (blank, comment-only and punctuation-only lines excluded), about 90% of them inside a single declaration: SyncSettingsFragment (102-1354). The bar is 500 significant lines; this is 170 over it, 1.34× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: firedown/UpdateDownloader.java app/src/main/java/com/solarized/firedown/UpdateDownloader.java — FileTooLong — 646 significant lines (blank, comment-only and punctuation-only lines excluded), about 96% of them inside a single declaration: UpdateDownloader (52-1233). The bar is 500 significant lines; this is 146 over it, 1.29× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: repository/GeckoStateDataRepository.java app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java — FileTooLong — 646 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 146 over it, 1.29× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: manager/DownloadEngine.java app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java — FileTooLong — 594 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: DownloadEngine (82-1218). The bar is 500 significant lines; this is 94 over it, 1.19× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: firedown/GlideHelper.java app/src/main/java/com/solarized/firedown/GlideHelper.java — FileTooLong — 589 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: GlideHelper (59-1252). The bar is 500 significant lines; this is 89 over it, 1.18× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: geckoview/GeckoInspectTask.java app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java — FileTooLong — 585 significant lines (blank, comment-only and punctuation-only lines excluded), about 94% of them inside a single declaration: GeckoInspectTask (47-1073). The bar is 500 significant lines; this is 85 over it, 1.17× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: geckoview/GeckoState.java app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java — FileTooLong — 566 significant lines (blank, comment-only and punctuation-only lines excluded), about 94% of them inside a single declaration: GeckoState (39-1434). The bar is 500 significant lines; this is 66 over it, 1.13× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: sabr/SabrDownloader.java app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java — FileTooLong — 566 significant lines (blank, comment-only and punctuation-only lines excluded), about 97% of them inside a single declaration: SabrDownloader (39-1033). The bar is 500 significant lines; this is 66 over it, 1.13× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: sync/FolderStore.java app/src/main/java/com/solarized/firedown/sync/FolderStore.java — FileTooLong — 557 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 57 over it, 1.11× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: fragments/DownloadFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java — FileTooLong — 556 significant lines (blank, comment-only and punctuation-only lines excluded), about 87% of them inside a single declaration: DownloadFragment (84-1063). The bar is 500 significant lines; this is 56 over it, 1.11× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: settings/CloudBackupFileAdapter.java app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java — FileTooLong — 545 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 45 over it, 1.09× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: fragments/BaseFocusFragment.java app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java — FileTooLong — 527 significant lines (blank, comment-only and punctuation-only lines excluded), about 86% of them inside a single declaration: BaseFocusFragment (86-936). The bar is 500 significant lines; this is 27 over it, 1.05× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: REDACTED REDACTED — FileTooLong — 523 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: WebDavClient (71-825). The bar is 500 significant lines; this is 23 over it, 1.05× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • + 3 more in this group — see findings.md.
D3 · God Classes · ClassTooLong · ×25
  • ClassTooLong: BrowserFragment app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:136 — ClassTooLong — 2100 significant lines (blank, comment-only and punctuation-only lines excluded), 140 methods. The bar is 400 significant lines; this is 1700 over it, 5.25× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: AddonManager app/src/main/java/com/solarized/firedown/addons/AddonManager.java:88 — ClassTooLong — 1337 significant lines (blank, comment-only and punctuation-only lines excluded), 100 methods. The bar is 400 significant lines; this is 937 over it, 3.34× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: MediaViewerFragment app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:129 — ClassTooLong — 1169 significant lines (blank, comment-only and punctuation-only lines excluded), 73 methods. The bar is 400 significant lines; this is 769 over it, 2.92× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: GeckoComponents app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:79 — ClassTooLong — 1107 significant lines (blank, comment-only and punctuation-only lines excluded), 22 methods. The bar is 400 significant lines; this is 707 over it, 2.77× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: CloudBackupListFragment app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:94 — ClassTooLong — 782 significant lines (blank, comment-only and punctuation-only lines excluded), 55 methods. The bar is 400 significant lines; this is 382 over it, 1.96× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: BaseDownloadFragment app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:89 — ClassTooLong — 756 significant lines (blank, comment-only and punctuation-only lines excluded), 56 methods. The bar is 400 significant lines; this is 356 over it, 1.89× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: DownloadItemAdapter app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:62 — ClassTooLong — 756 significant lines (blank, comment-only and punctuation-only lines excluded), 55 methods. The bar is 400 significant lines; this is 356 over it, 1.89× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: S3Client REDACTED:86 — ClassTooLong — 745 significant lines (blank, comment-only and punctuation-only lines excluded), 45 methods. The bar is 400 significant lines; this is 345 over it, 1.86× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: BrowserOptionAdapter app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:74 — ClassTooLong — 731 significant lines (blank, comment-only and punctuation-only lines excluded), 56 methods. The bar is 400 significant lines; this is 331 over it, 1.83× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: UpdateDownloader app/src/main/java/com/solarized/firedown/UpdateDownloader.java:52 — ClassTooLong — 622 significant lines (blank, comment-only and punctuation-only lines excluded), 54 methods. The bar is 400 significant lines; this is 222 over it, 1.56× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: SyncSettingsFragment app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:102 — ClassTooLong — 603 significant lines (blank, comment-only and punctuation-only lines excluded), 44 methods. The bar is 400 significant lines; this is 203 over it, 1.51× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: DownloadEngine app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:82 — ClassTooLong — 554 significant lines (blank, comment-only and punctuation-only lines excluded), 31 methods. The bar is 400 significant lines; this is 154 over it, 1.39× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: GeckoInspectTask app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:47 — ClassTooLong — 551 significant lines (blank, comment-only and punctuation-only lines excluded), 26 methods. The bar is 400 significant lines; this is 151 over it, 1.38× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: SabrDownloader app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:39 — ClassTooLong — 547 significant lines (blank, comment-only and punctuation-only lines excluded), 33 methods. The bar is 400 significant lines; this is 147 over it, 1.37× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: GlideHelper app/src/main/java/com/solarized/firedown/GlideHelper.java:59 — ClassTooLong — 538 significant lines (blank, comment-only and punctuation-only lines excluded), 43 methods. The bar is 400 significant lines; this is 138 over it, 1.35× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: GeckoState app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:39 — ClassTooLong — 533 significant lines (blank, comment-only and punctuation-only lines excluded), 128 methods. The bar is 400 significant lines; this is 133 over it, 1.33× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: SabrMessages app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:12 — ClassTooLong — 515 significant lines (blank, comment-only and punctuation-only lines excluded), 2 methods. The bar is 400 significant lines; this is 115 over it, 1.29× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: DownloadFragment app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:84 — ClassTooLong — 486 significant lines (blank, comment-only and punctuation-only lines excluded), 45 methods. The bar is 400 significant lines; this is 86 over it, 1.22× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: WebDavClient REDACTED:71 — ClassTooLong — 485 significant lines (blank, comment-only and punctuation-only lines excluded), 27 methods. The bar is 400 significant lines; this is 85 over it, 1.21× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: FilmstripTrimSlider app/src/main/java/com/solarized/firedown/ui/FilmstripTrimSlider.java:50 — ClassTooLong — 468 significant lines (blank, comment-only and punctuation-only lines excluded), 40 methods. The bar is 400 significant lines; this is 68 over it, 1.17× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: BaseFocusFragment app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:86 — ClassTooLong — 451 significant lines (blank, comment-only and punctuation-only lines excluded), 42 methods. The bar is 400 significant lines; this is 51 over it, 1.13× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: UpdateAvailableSheet app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:71 — ClassTooLong — 441 significant lines (blank, comment-only and punctuation-only lines excluded), 33 methods. The bar is 400 significant lines; this is 41 over it, 1.10× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: SettingsFragment app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:61 — ClassTooLong — 427 significant lines (blank, comment-only and punctuation-only lines excluded), 22 methods. The bar is 400 significant lines; this is 27 over it, 1.07× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Fmp4Muxer app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:62 — ClassTooLong — 417 significant lines (blank, comment-only and punctuation-only lines excluded), 41 methods. The bar is 400 significant lines; this is 17 over it, 1.04× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: SecurityStateSheetDialogFragment app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:62 — ClassTooLong — 414 significant lines (blank, comment-only and punctuation-only lines excluded), 16 methods. The bar is 400 significant lines; this is 14 over it, 1.04× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D4 · Code Duplication · Duplicated block (7 lines × 2) · ×25
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/Preferences.java:939 — app/src/main/java/com/solarized/firedown/Preferences.java:939-945 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:427-433 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/Preferences.java:939` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:491 — app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:491-497 | app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:671-677 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:671` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:110 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:110-116 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:136-142 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:110` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:2057 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:2057-2063 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:2094-2102 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:2057` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadIntents.java:156 — app/src/main/java/com/solarized/firedown/manager/DownloadIntents.java:156-162 | app/src/main/java/com/solarized/firedown/manager/ItemLists.java:195-201 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/DownloadIntents.java:156` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/okhttp/OriginInterceptor.java:60 — app/src/main/java/com/solarized/firedown/okhttp/OriginInterceptor.java:60-66 | app/src/main/java/com/solarized/firedown/utils/BrowserHeaders.java:125-131 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/p2pshare/P2pLanServer.java:120 — app/src/main/java/com/solarized/firedown/p2pshare/P2pLanServer.java:120-126 | app/src/main/java/com/solarized/firedown/p2pshare/P2pLoopbackServer.java:94-100 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:282 — app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:282-288 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:400-407 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:282` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) REDACTED:292 — REDACTED:292-298 | REDACTED:274-280 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:292` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:335 — app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:335-341 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:221-227 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:203 — app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:203-209 | app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:263-269 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:202 — app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:202-208 | app/src/main/java/com/solarized/firedown/manager/TimedTextStrategy.java:138-144 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:202` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:278 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:278-286 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:129-135 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:122 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:122-128 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegThumbnailer.java:203-209 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:121 — app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:121-127 | app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:299-305 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java` and `app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/settings/FeedbackFragment.java:169 — app/src/main/java/com/solarized/firedown/settings/FeedbackFragment.java:169-175 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:341-347 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:105 — app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:105-111 | app/src/main/java/com/solarized/firedown/sync/model/VaultManifest.java:96-102 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:579 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:579-585 | app/src/main/java/com/solarized/firedown/ui/adapters/StorageReviewAdapter.java:135-141 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/manager/ServiceActions.java:21 — app/src/main/java/com/solarized/firedown/manager/ServiceActions.java:21-27 | app/src/main/java/com/solarized/firedown/manager/UrlType.java:34-40 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1740 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1740-1746 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:602-615 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:205 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:205-211 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:78-84 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 63 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) REDACTED:620 — REDACTED:620-626 | REDACTED:1193-1199 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:620` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 2) REDACTED:124 — REDACTED:124-130 | REDACTED:85-91 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:124` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) REDACTED:407 — REDACTED:407-413 | REDACTED:879-885 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (7 lines × 2) REDACTED:257 — REDACTED:257-263 | REDACTED:772-778 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
AC3 · Page structure · Page without a main landmark · ×23
  • Page without a main landmark design/home-card-border-options.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-flame-glow.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-incognito-illus.html:1 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-incognito-logo.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-incognito-minimal.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-minimal-final.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-minimal.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-mockups-minimal.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-mockups.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-onboarding-borderless.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-onboarding-final.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-onboarding-zero.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-safe-column.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-stats-alternatives.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/home-subtitle-options.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/inc_landscape.html:1 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark design/pills_card.html:1 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/active-download-card.html:1 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/addons.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/bookmark-edit-improvements.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/bookmarks-card-sketches.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/browsesubtitlegrouping.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark sketches/browsesubtitleunified.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
D4 · Code Duplication · Duplicated block (6 lines × 2) · ×22
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:759 — app/src/main/java/com/solarized/firedown/addons/AddonManager.java:759-764 | app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1058-1063 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:238 — app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:238-243 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:202-207 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:238` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:51 — app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:51-56 | app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:136-141 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java` and `app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:237 — app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:237-242 | app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:619-624 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:205 — app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:205-210 | app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:217-222 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:205` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:652 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:652-657 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1111-1117 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:652` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1047 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1047-1052 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1061-1066 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1047` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:67 — app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:67-72 | app/src/main/java/com/solarized/firedown/sync/model/VaultManifest.java:66-71 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:67` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkEditFragment.java:269 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkEditFragment.java:269-274 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:277-282 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkEditFragment.java:269` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/addons/AddonInfo.java:101 — app/src/main/java/com/solarized/firedown/addons/AddonInfo.java:101-106 | app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1735-1740 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) REDACTED:159 — REDACTED:159-164 | REDACTED:61-66 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:541 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:541-546 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:230-235 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:629 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:629-634 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:257-265 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 63 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:133 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:133-138 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:111-116 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:251 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:251-256 | app/src/main/java/com/solarized/firedown/geckoview/prompt/GeckoPromptManager.java:106-111 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:909 — app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:909-914 | app/src/main/java/com/solarized/firedown/phone/dialogs/PopupHomeSheetDialogFragment.java:149-154 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:1180 — app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:1180-1185 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:233-245 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:682 — app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:682-687 | app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:782-787 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (6 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:114 — app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:114-119 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:138-143 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (6 lines × 2) scripts/datauri-harness/src/DataUrisHarness.java:19 — scripts/datauri-harness/src/DataUrisHarness.java:19-24 | scripts/player-subtitles-harness/src/PlayerSubtitlesHarness.java:24-29 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/datauri-harness/src/DataUrisHarness.java:19` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) REDACTED:1249 — REDACTED:1249-1254 | REDACTED:675-680 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1249` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) REDACTED:583 — REDACTED:583-588 | REDACTED:1013-1018 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (9 lines × 2) · ×19
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:221 — app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:221-229 | app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:231-239 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:172 — app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:172-180 | app/src/main/java/com/solarized/firedown/addons/XpiManifest.java:195-203 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:172` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:74 — app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:74-82 | app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:132-140 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:74` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1412 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1412-1420 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1480-1489 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:186 — app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:186-194 | app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:307-315 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:332 — app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:332-340 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1905-1913 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:312 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:312-320 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:722-730 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:312` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:731` calls `renderRows` and `app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:321` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:183 — app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:183-191 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:247-255 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:183` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/utils/UrlStringUtils.java:200 — app/src/main/java/com/solarized/firedown/utils/UrlStringUtils.java:200-208 | app/src/main/java/com/solarized/firedown/utils/UrlStringUtils.java:211-219 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:618 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:618-626 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:444-452 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:413 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:413-421 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:771-779 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:816 — app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:816-824 | app/src/main/java/com/solarized/firedown/sync/SyncManager.java:364-372 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadIntents.java:145 — app/src/main/java/com/solarized/firedown/manager/DownloadIntents.java:145-153 | app/src/main/java/com/solarized/firedown/manager/ItemLists.java:226-234 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (9 lines × 2) scripts/addons-harness/src/com/solarized/firedown/harness/AddonsHarness.java:49 — scripts/addons-harness/src/com/solarized/firedown/harness/AddonsHarness.java:49-57 | scripts/visit-harness/src/com/solarized/firedown/harness/VisitHarness.java:22-30 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/addons-harness/src/com/solarized/firedown/harness/AddonsHarness.java:49` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) REDACTED:1496 — REDACTED:1496-1504 | REDACTED:1524-1532 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1496` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (9 lines × 2) scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:154 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:154-162 | scripts/engine-harness/src/com/solarized/firedown/harness/EngineStress.java:258-266 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:154` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) REDACTED:882 — REDACTED:882-890 | REDACTED:896-904 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:882` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) REDACTED:137 — REDACTED:137-145 | REDACTED:98-106 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (9 lines × 2) scripts/addons-harness/src/com/solarized/firedown/harness/AddonsHarness.java:31 — scripts/addons-harness/src/com/solarized/firedown/harness/AddonsHarness.java:31-39 | scripts/applinks-harness/src/com/solarized/firedown/harness/AppLinksHarness.java:18-26 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (8 lines × 2) · ×18
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:96 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:96-103 | app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:467-474 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:94` calls `readInt` and `app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:465` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:299 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:299-306 | app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:504-511 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:297` calls `writeInt` and `app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:502` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:335 — app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:335-342 | app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1154-1161 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1162` calls `updateCount`, `publishProgress` and `app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:343` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:901 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:901-908 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:306-315 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:901` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:123 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:123-130 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:199-206 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 47 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:123` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:419 — app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:419-426 | app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:444-451 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:419` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:470 — app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:470-477 | app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:474-481 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:415 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:415-422 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:283-290 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java` and `app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 55 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:441 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:441-448 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:323-330 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java` and `app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 55 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:329 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:329-336 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1339-1346 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:87 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:87-94 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:146-156 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 47 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:239 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:239-246 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:278-285 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:164 — app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:164-171 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:205-212 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java` and `app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:149 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:149-159 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:170-177 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java` and `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 66 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:340 — app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:340-347 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1552-1559 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (8 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:1188 — app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:1188-1195 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:248-255 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) scripts/sabr-harness/src/com/solarized/firedown/sabr/SabrHarness.java:124 — scripts/sabr-harness/src/com/solarized/firedown/sabr/SabrHarness.java:124-131 | scripts/sabr-harness/src/com/solarized/firedown/sabr/SabrHarness.java:142-149 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/sabr-harness/src/com/solarized/firedown/sabr/SabrHarness.java:124` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) scripts/backup-fault-harness/mutants.py:75 — scripts/backup-fault-harness/mutants.py:75-82 | scripts/s3-harness/mutants.py:100-107 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D3 · God Classes · MethodTooLong · ×16
  • MethodTooLong: BrowserFragment.onViewCreated app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736 — MethodTooLong — onViewCreated runs 360 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 260 over it, 3.60× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: HttpDownloadStrategy.execute app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:60 — MethodTooLong — execute runs 170 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 70 over it, 1.70× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: M3U8Parser.parseMaster app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:97 — MethodTooLong — parseMaster runs 126 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 26 over it, 1.26× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: SabrDownloader.download app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:278 — MethodTooLong — download runs 120 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 20 over it, 1.20× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: CloudBackupListFragment.onViewCreated app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:229 — MethodTooLong — onViewCreated runs 119 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 19 over it, 1.19× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DeezerStrategy.execute app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:73 — MethodTooLong — execute runs 118 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 18 over it, 1.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: SabrStrategy.executeInternal app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:125 — MethodTooLong — executeInternal runs 115 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 15 over it, 1.15× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: HomeFragment.onViewCreated app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290 — MethodTooLong — onViewCreated runs 114 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 14 over it, 1.14× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: GeckoStreamStrategy.execute app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:48 — MethodTooLong — execute runs 112 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 12 over it, 1.12× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: SettingsActivity.onCreate app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:110 — MethodTooLong — onCreate runs 111 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 11 over it, 1.11× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: SabrMessages.buildAbrRequest app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:551 — MethodTooLong — buildAbrRequest runs 107 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 7 over it, 1.07× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: FFmpegMuxStrategy.execute app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:61 — MethodTooLong — execute runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: MegaStrategy.execute app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:66 — MethodTooLong — execute runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: VaultBackupWorker.doWork app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:260 — MethodTooLong — doWork runs 104 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 4 over it, 1.04× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: BrowserOptionHolderSheetDialogFragment.onViewCreated app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:260 — MethodTooLong — onViewCreated runs 101 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1 over it, 1.01× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: HomeIncognitoFragment.onViewCreated app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:224 — MethodTooLong — onViewCreated runs 101 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1 over it, 1.01× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D4 · Code Duplication · Edited copy of a member (11 corresponding lines) · ×16
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:507 — app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:507-517 | app/src/main/java/com/solarized/firedown/sync/VaultThumbnail.java:379-390 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:702 — app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:702-712 | scripts/update-harness/src/com/solarized/firedown/update/UpdateFuzz.java:305-317 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/manager/ItemLists.java:100 — app/src/main/java/com/solarized/firedown/manager/ItemLists.java:100-110 | app/src/main/java/com/solarized/firedown/manager/ItemLists.java:142-153 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:334 — app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:334-344 | app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1153-1175 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/update/UpdatePatch.java:307 — app/src/main/java/com/solarized/firedown/update/UpdatePatch.java:307-318 | REDACTED:185-195 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/DownloadsOptionDialogFragment.java:267 — app/src/main/java/com/solarized/firedown/phone/dialogs/DownloadsOptionDialogFragment.java:267-277 | app/src/main/java/com/solarized/firedown/phone/dialogs/DownloadsOptionDialogFragment.java:280-291 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/manager/ItemLists.java:156 — app/src/main/java/com/solarized/firedown/manager/ItemLists.java:156-167 | app/src/main/java/com/solarized/firedown/manager/ItemLists.java:170-180 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:724 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:724-734 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:491-501 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1291 — app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1291-1301 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1304-1315 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1616 — app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1616-1626 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1644-1655 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:374 — app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:374-384 | app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:390-402 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/player/PlayerSubtitles.java:190 — app/src/main/java/com/solarized/firedown/phone/player/PlayerSubtitles.java:190-200 | app/src/main/java/com/solarized/firedown/phone/player/PlayerSubtitles.java:220-231 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:112 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:112-122 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegGifMaker.java:116-126 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:365 — app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:365-375 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1793-1807 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/SafeFolderHeaderAdapter.java:53 — app/src/main/java/com/solarized/firedown/ui/adapters/SafeFolderHeaderAdapter.java:53-63 | app/src/main/java/com/solarized/firedown/ui/adapters/SyncBannerAdapter.java:92-102 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:691 — scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:691-701 | scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:784-798 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×13
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Duplicated block (5 lines × 2) · ×13
  • Duplicated block (5 lines × 2) app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:135 — app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:135-139 | REDACTED:625-629 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:135` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:934 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:934-938 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:394-398 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:934` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) app/src/main/java/com/solarized/firedown/utils/ContentUriUtils.java:247 — app/src/main/java/com/solarized/firedown/utils/ContentUriUtils.java:247-251 | app/src/main/java/com/solarized/firedown/utils/ContentUriUtils.java:300-304 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:753 — app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:753-757 | app/src/main/java/com/solarized/firedown/phone/dialogs/PopupHomeSheetDialogFragment.java:136-140 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (5 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:700 — app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:700-704 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:111-115 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:700` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:699` calls `abs`, `SecureRandom`, `nextInt` and `app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:110` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 2) REDACTED:892 — REDACTED:892-896 | REDACTED:906-910 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:892` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) REDACTED:1157 — REDACTED:1157-1161 | REDACTED:1174-1178 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:560 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:560-564 | scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:574-578 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:560` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (5 lines × 2) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:784 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:784-788 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:825-829 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) REDACTED:496 — REDACTED:496-500 | REDACTED:944-948 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) REDACTED:1241 — REDACTED:1241-1245 | REDACTED:667-671 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1241` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:721 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:721-725 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:760-764 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:721` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) scripts/dump_full_local.py:128 — scripts/dump_full_local.py:128-132 | scripts/dump_full_local.py:137-141 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/dump_full_local.py:128` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `scripts/dump_full_local.py:126` calls `splitext`, `safe_name`, `group` and `scripts/dump_full_local.py:135` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
X2 · Cancellation propagation · Async function without AbortSignal · ×13
  • Async function without AbortSignal: loadSolver app/src/main/assets/youtube/background.js:42 — `loadSolver` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchMainPlayer app/src/main/assets/youtube/background.js:516 — `fetchMainPlayer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchAndCachePlayer app/src/main/assets/youtube/background.js:773 — `fetchAndCachePlayer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: processVideo app/src/main/assets/youtube/background.js:1975 — `processVideo` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchMediaList app/src/main/assets/webrequests/js/page-state-bridge.js:1470 — `fetchMediaList` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchKickChannel app/src/main/assets/webrequests/js/parsers/kick.js:73 — `fetchKickChannel` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchKickClip app/src/main/assets/webrequests/js/parsers/kick.js:101 — `fetchKickClip` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchKickVideo app/src/main/assets/webrequests/js/parsers/kick.js:141 — `fetchKickVideo` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchTwitchLiveStream app/src/main/assets/webrequests/js/parsers/twitch.js:229 — `fetchTwitchLiveStream` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchTwitchVod app/src/main/assets/webrequests/js/parsers/twitch.js:338 — `fetchTwitchVod` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchTwitchClip app/src/main/assets/webrequests/js/parsers/twitch.js:431 — `fetchTwitchClip` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: verifyResumeTail app/src/main/assets/p2pshare/engine-page.js:737 — `verifyResumeTail` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: pumpFile app/src/main/assets/p2pshare/engine-page.js:831 — `pumpFile` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
D4 · Code Duplication · Edited copy of a member (13 corresponding lines) · ×12
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1043 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1043-1055 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:1057-1069 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:144 — app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:144-156 | app/src/main/java/com/solarized/firedown/manager/tasks/SaveFrameTask.java:157-174 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:252 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:252-264 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:235-247 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoUblockHelper.java:290 — app/src/main/java/com/solarized/firedown/geckoview/GeckoUblockHelper.java:290-302 | app/src/main/java/com/solarized/firedown/geckoview/GeckoUblockHelper.java:305-317 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:513 — app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:513-530 | app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:617-629 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:1078 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:1078-1090 | app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:1092-1104 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/StorageReviewFragment.java:113 — app/src/main/java/com/solarized/firedown/phone/fragments/StorageReviewFragment.java:113-125 | app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:72-84 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:311 — app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:311-323 | app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:412-425 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:293 — app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:293-307 | app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:309-321 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:702 — app/src/main/java/com/solarized/firedown/sync/FolderStore.java:702-715 | app/src/main/java/com/solarized/firedown/sync/FolderStore.java:881-893 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:124 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:124-140 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegGifMaker.java:128-140 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:1054 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:1054-1066 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:1068-1082 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (10 lines × 2) · ×12
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:878 — app/src/main/java/com/solarized/firedown/UpdateDownloader.java:878-887 | app/src/main/java/com/solarized/firedown/UpdateDownloader.java:1076-1085 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/UpdateDownloader.java:878` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1667 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1667-1676 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1724-1733 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:208 — app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:208-217 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:168-177 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:141 — app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:141-150 | app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:186-195 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:141` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:66 — app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:66-75 | app/src/main/java/com/solarized/firedown/manager/tasks/OutSafeTask.java:65-74 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:66` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:722 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:722-731 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1699-1708 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:722` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseTabsFragment.java:200 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseTabsFragment.java:200-209 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseTabsFragment.java:305-314 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:198 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:198-207 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:125-134 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:150 — app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:150-159 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:725-734 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:736` calls `OptIn` and `app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:161` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10 lines × 2) REDACTED:1068 — REDACTED:1068-1077 | REDACTED:556-565 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1068` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) app/src/main/java/com/solarized/firedown/data/models/DownloadsViewModel.java:235 — app/src/main/java/com/solarized/firedown/data/models/DownloadsViewModel.java:235-244 | app/src/main/java/com/solarized/firedown/data/models/WebHistoryViewModel.java:76-85 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (10 lines × 2) REDACTED:165 — REDACTED:165-174 | REDACTED:607-616 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Edited copy of a member (19 corresponding lines) · ×11
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:128 — app/src/main/java/com/solarized/firedown/crash/AnonymousPost.java:128-146 | app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:2480-2504 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/sync/S3Check.java:122 — app/src/main/java/com/solarized/firedown/sync/S3Check.java:122-142 | app/src/main/java/com/solarized/firedown/sync/WebDavCheck.java:123-141 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) REDACTED:1063 — REDACTED:1063-1084 | REDACTED:551-569 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:103 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:103-122 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:82-100 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/BaseActivity.java:778 — app/src/main/java/com/solarized/firedown/BaseActivity.java:778-796 | app/src/main/java/com/solarized/firedown/BaseActivity.java:798-816 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:129 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:129-151 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:98-116 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/settings/CloudDeleteFragment.java:105 — app/src/main/java/com/solarized/firedown/settings/CloudDeleteFragment.java:105-123 | app/src/main/java/com/solarized/firedown/settings/CloudDeleteFragment.java:132-150 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) REDACTED:1242 — REDACTED:1242-1260 | REDACTED:788-806 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:628 — app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:628-646 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1197-1216 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/sync/BackupStores.java:142 — app/src/main/java/com/solarized/firedown/sync/BackupStores.java:142-160 | app/src/main/java/com/solarized/firedown/sync/BackupStores.java:169-187 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/NewTabSheetDialogFragment.java:38 — app/src/main/java/com/solarized/firedown/phone/dialogs/NewTabSheetDialogFragment.java:38-56 | app/src/main/java/com/solarized/firedown/phone/dialogs/WebOptionSheetDialogFragment.java:107-127 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (11 lines × 2) · ×11
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:254 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:254-264 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:237-247 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:254` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:79 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:79-89 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:102-112 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:79` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java:79 — app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java:79-89 | app/src/main/java/com/solarized/firedown/phone/VaultActivity.java:33-43 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:143 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:143-153 | app/src/main/java/com/solarized/firedown/phone/dialogs/SaveFileDialog.java:223-233 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:143` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:700 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:700-710 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:731-741 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:700` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1163 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1163-1173 | app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1185-1195 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:81 — app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:81-91 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:409-419 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java` and `app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:81` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/ui/CloudMark.java:122 — app/src/main/java/com/solarized/firedown/ui/CloudMark.java:122-132 | app/src/main/java/com/solarized/firedown/ui/CloudMark.java:150-160 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/ui/CloudMark.java:122` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind `facts` to `String` in one and `CharSequence` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (11 lines × 2) REDACTED:133 — REDACTED:133-143 | app/src/main/java/com/solarized/firedown/sync/VaultEngine.java:318-328 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:43 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:43-53 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegGifMaker.java:49-59 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (11 lines × 2) REDACTED:601 — REDACTED:601-611 | REDACTED:1182-1192 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Edited copy of a member (9 corresponding lines) · ×10
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:440 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:440-448 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:322-330 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/sync/crypto/Hex.java:14 — app/src/main/java/com/solarized/firedown/sync/crypto/Hex.java:14-22 | app/src/main/java/com/solarized/firedown/update/UpdatePatch.java:320-328 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:469 — app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:469-477 | app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:473-481 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:125 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:125-135 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:42-50 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:365 — app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:365-373 | app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:385-394 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/phone/LockActivity.java:95 — app/src/main/java/com/solarized/firedown/phone/LockActivity.java:95-103 | app/src/main/java/com/solarized/firedown/phone/fragments/LockFragment.java:239-247 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/media/GeckoMediaPlaybackService.java:588 — app/src/main/java/com/solarized/firedown/geckoview/media/GeckoMediaPlaybackService.java:588-596 | app/src/main/java/com/solarized/firedown/phone/player/PlayerPlaybackService.java:388-397 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:500 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:500-509 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:511-519 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) app/src/main/java/com/solarized/firedown/sync/S3Signer.java:241 — app/src/main/java/com/solarized/firedown/sync/S3Signer.java:241-249 | REDACTED:762-770 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) REDACTED:269 — REDACTED:269-277 | REDACTED:656-664 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
P7 · Outbound HTTP resilience · Outbound HTTP without resilience · ×10
  • Outbound HTTP without resilience app/src/main/assets/webrequests/js/page-state-bridge.js:1473 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/background.js:60 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/background.js:528 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/background.js:785 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/background.js:800 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/background.js:2158 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/content.js:83 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/assets/youtube/content.js:102 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/java/com/solarized/firedown/sync/ServerTrust.java:99 — `new OkHttpClient.Builder(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience app/src/main/java/com/solarized/firedown/sync/ServerTrust.java:110 — `new OkHttpClient(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
D4 · Code Duplication · Edited copy of a member (10 corresponding lines) · ×9
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:98 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:98-107 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:160-173 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:1145 — app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:1145-1154 | REDACTED:653-664 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:361 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:361-370 | app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:375-386 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/p2pshare/P2pLanServer.java:116 — app/src/main/java/com/solarized/firedown/p2pshare/P2pLanServer.java:116-128 | app/src/main/java/com/solarized/firedown/p2pshare/P2pLoopbackServer.java:92-101 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/BaseActivity.java:406 — app/src/main/java/com/solarized/firedown/BaseActivity.java:406-419 | app/src/main/java/com/solarized/firedown/BaseActivity.java:421-430 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:759 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:759-770 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:533-542 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/Preferences.java:882 — app/src/main/java/com/solarized/firedown/Preferences.java:882-891 | app/src/main/java/com/solarized/firedown/Preferences.java:893-902 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:538 — app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:538-547 | app/src/main/java/com/solarized/firedown/settings/AboutFragment.java:201-211 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:656 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:656-668 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:689-698 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (12 corresponding lines) · ×9
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:303 — app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:303-314 | app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:325-336 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:386 — app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:386-397 | app/src/main/java/com/solarized/firedown/settings/TranslationsFragment.java:399-410 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/ui/CloudMark.java:91 — app/src/main/java/com/solarized/firedown/ui/CloudMark.java:91-102 | app/src/main/java/com/solarized/firedown/ui/CloudMark.java:120-132 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/TabsFragment.java:133 — app/src/main/java/com/solarized/firedown/phone/fragments/TabsFragment.java:133-145 | app/src/main/java/com/solarized/firedown/phone/fragments/TabsIncognitoFragment.java:75-86 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/StoragePaths.java:302 — app/src/main/java/com/solarized/firedown/StoragePaths.java:302-313 | app/src/main/java/com/solarized/firedown/StoragePaths.java:315-326 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/donation/DonationPrompt.java:70 — app/src/main/java/com/solarized/firedown/donation/DonationPrompt.java:70-81 | app/src/main/java/com/solarized/firedown/settings/AboutFragment.java:514-526 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:1221 — app/src/main/java/com/solarized/firedown/UpdateDownloader.java:1221-1232 | app/src/main/java/com/solarized/firedown/addons/AddonPermissions.java:136-147 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1033 — app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1033-1044 | app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:1402-1413 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimServers.java:134 — scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimServers.java:134-146 | scripts/webdav-harness/src/com/solarized/firedown/sync/FakeDav.java:101-112 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (7 corresponding lines) · ×9
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java:65 — app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java:65-71 | app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:132-144 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:423 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pReceiveFragment.java:423-429 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:782-788 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/sync/SyncManager.java:172 — app/src/main/java/com/solarized/firedown/sync/SyncManager.java:172-180 | app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:202-208 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:253 — app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:253-259 | app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHelpFragment.java:23-38 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:632 — app/src/main/java/com/solarized/firedown/phone/dialogs/TranslateSheetDialogFragment.java:632-640 | app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:2998-3004 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/DeleteDownloadsDialogFragment.java:85 — app/src/main/java/com/solarized/firedown/phone/dialogs/DeleteDownloadsDialogFragment.java:85-91 | app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:579-585 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) REDACTED:295 — REDACTED:295-301 | REDACTED:277-283 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) scripts/potoken-harness/src/com/solarized/firedown/geckoview/Harness.java:25 — scripts/potoken-harness/src/com/solarized/firedown/geckoview/Harness.java:25-36 | scripts/potoken-harness/src/com/solarized/firedown/geckoview/LeakHarness.java:26-32 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) REDACTED:340 — REDACTED:340-347 | REDACTED:197-203 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (6 corresponding lines) · ×9
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:307 — app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:307-316 | app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:611-616 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) REDACTED:69 — REDACTED:69-74 | REDACTED:77-82 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:125 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:125-130 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:103-108 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:141 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:141-146 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:119-124 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/crash/CrashReportSheet.java:280 — app/src/main/java/com/solarized/firedown/crash/CrashReportSheet.java:280-286 | app/src/main/java/com/solarized/firedown/phone/player/PlaybackDebugInfo.java:169-174 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:338 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:338-343 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:955-962 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:159 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:159-164 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:240-247 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/sync/crypto/Pow.java:74 — app/src/main/java/com/solarized/firedown/sync/crypto/Pow.java:74-79 | scripts/update-harness/src/com/solarized/firedown/update/UpdateFuzz.java:319-324 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/BaseDialogFragment.java:90 — app/src/main/java/com/solarized/firedown/phone/dialogs/BaseDialogFragment.java:90-95 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:413-421 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (12 lines × 2) · ×9
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:527 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:527-538 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:216-227 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:52 — app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:52-63 | app/src/main/java/com/solarized/firedown/manager/tasks/SaveFrameTask.java:57-68 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:743 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:743-754 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:756-767 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3434 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3434-3445 | app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:4126-4137 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:370 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:370-381 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:309-320 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:370` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/BaseActivity.java:780 — app/src/main/java/com/solarized/firedown/BaseActivity.java:780-791 | app/src/main/java/com/solarized/firedown/BaseActivity.java:800-811 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/BaseActivity.java:792` calls `setAnchorView` and `app/src/main/java/com/solarized/firedown/BaseActivity.java:813` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:346 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:346-357 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegThumbnailer.java:167-178 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) REDACTED:700 — REDACTED:700-711 | REDACTED:1228-1239 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:700` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) scripts/replace.py:11 — scripts/replace.py:11-22 | scripts/upper.py:11-22 — before extracting anything, compare `scripts/replace.py` and `scripts/upper.py` as WHOLE FILES: 91% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 1 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (3.2 · ×8
  • Low contrast colour pair in CSS (3.2:1) design/home-card-border-options.html:24 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-incognito-logo.html:29 — `.phone.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-incognito-minimal.html:18 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-minimal-final.html:17 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-minimal.html:26 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-onboarding-borderless.html:17 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-onboarding-final.html:19 — `.lt .omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.2:1) design/home-onboarding-zero.html:52 — `.omni` sets color: #7d7b86 on background-color: #E5E2E1 — 3.2:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (4.1 · ×8
  • Low contrast colour pair in CSS (4.1:1) design/home-card-border-options.html:24 — `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-minimal-final.html:17 — `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-minimal.html:26 — `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-mockups-minimal.html:43 — `.dark .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-mockups.html:72 — `.dark .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-onboarding-borderless.html:17 — `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) design/home-onboarding-final.html:19 — `.dk .omni` sets color: #7d7d86 on background-color: #1e1e21 — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (4.1:1) sketches/home-ux-alternatives.html:125 — `.toolbar .urlbar` sets color: #8b8794 on background-color: #2a2a2e — 4.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AX2 · Stateful singletons · Stateful singleton · ×8
  • Stateful singleton: AddonManager app/src/main/java/com/solarized/firedown/addons/AddonManager.java:88 — `AddonManager` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mActions, mInstalled, mPageInstallInFlight, mDeclinedHosts, mPromptQueue, mRuntime; e.g. `mActions` in `actionState` at line 1931).
  • Stateful singleton: AmoCatalogClient app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:48 — `AmoCatalogClient` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mLoading; e.g. `mLoading` in `load` at line 93).
  • Stateful singleton: SearchRepository app/src/main/java/com/solarized/firedown/data/repository/SearchRepository.java:32 — `SearchRepository` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mEngineCache; e.g. `mEngineCache` in `loadSearchEngines` at line 82).
  • Stateful singleton: TaskRepository app/src/main/java/com/solarized/firedown/data/repository/TaskRepository.java:29 — `TaskRepository` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mRunningTaskSeq; e.g. `mRunningTaskSeq` in `trackRunningTask` at line 234).
  • Stateful singleton: GeckoComponents app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:79 — `GeckoComponents` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mPendingLocation; e.g. `mPendingLocation` in `onLocationPermissionResult` at line 327).
  • Stateful singleton: GeckoObserverRegistry app/src/main/java/com/solarized/firedown/geckoview/GeckoObserverRegistry.java:49 — `GeckoObserverRegistry` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mObservers; e.g. `mObservers` in `register` at line 63).
  • Stateful singleton: P2pShareController app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:123 — `P2pShareController` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mRecvPartFile, mWakeLock, mWifiLock, mRuntime, mSessionRegistrar, mState; e.g. `mRecvPartFile` in `acceptOffer` at line 1548).
  • Stateful singleton: Sorting app/src/main/java/com/solarized/firedown/Sorting.java:12 — `Sorting` is a singleton (@Singleton: the container shares one instance across every request thread) but mutates instance state outside any lock (mCurrentSortDownloads; e.g. `mCurrentSortDownloads` in `setCurrentSortDownloadsForId` at line 48).
D35 · Change Coupling · Change coupling · ×8
  • Change coupling: DownloadDao.java ↔ DownloadDataRepository.java app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java:1 — `app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java` and `app/src/main/java/com/solarized/firedown/data/repository/DownloadDataRepository.java` change together 93% of the time (14 of the 15 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 14 shared commits counted here, the most recent 3 are `0b6c2bc0` Safe Folder row: shown only once the vault holds something; `22d4fec1` Storage: "Free up space" removes phone copies of backed-up downloads; `63a302fa` Batch-delete downloads in one Room transaction — run `git show` on any of them.
  • Change coupling: BrowserDownloadEntity.java ↔ GeckoInspectEntity.java app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java:1 — `app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java` and `app/src/main/java/com/solarized/firedown/data/entity/GeckoInspectEntity.java` change together 64% of the time (7 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets). They sit in the same directory, and in this ecosystem sibling files there normally share one namespace/package — so a direct reference between them needs no import and this pass cannot see whether one exists. Read the pair before acting: if one file only DECLARES what the other consumes (a constants/types file beside its user), the co-change is definitional and the question is whether the split earns its keep; if they duplicate structure, extract the common part into a shared function or type they both call; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `835cfdcd` Capture: absorbed redirect targets, folded files, refined copies, lat…; `4d908b00` Captured: fix the clip names and duplicates the second device audit f…; `ce2618a0` Captured pin: re-stamp captures that arrive before the navigation com… — run `git show` on any of them.
  • Change coupling: DownloadDao.java ↔ HomeFragment.java app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java:1 — `app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` change together 60% of the time (9 of the 15 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 9 shared commits counted here, the most recent 3 are `bc00152a` Home: add a tappable two-figure subtitle under the wordmark; `24d1d996` Home: drop onboarding + tagline, remove all the now-dead code/strings; `2be7cd98` Home stats card: Safe Folder shows total size, count moves to footer — run `git show` on any of them.
  • Change coupling: CloudBackupFileAdapter.java ↔ CloudBackupItemSheetDialogFragment.java app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:1 — `app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java` and `app/src/main/java/com/solarized/firedown/settings/CloudBackupItemSheetDialogFragment.java` change together 57% of the time (8 of the 14 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets). They sit in the same directory, and in this ecosystem sibling files there normally share one namespace/package — so a direct reference between them needs no import and this pass cannot see whether one exists. Read the pair before acting: if one file only DECLARES what the other consumes (a constants/types file beside its user), the co-change is definitional and the question is whether the split earns its keep; if they duplicate structure, extract the common part into a shared function or type they both call; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 8 shared commits counted here, the most recent 3 are `9d8a32b1` Backups list: render from the LOCAL file when it exists, like Downloads; `eebdc7cf` Backups: move the list's thumbnails onto Glide, delete both hand-roll…; `a054515d` Backups: move the cloud-only fact to the remove decision, drop the ro… — run `git show` on any of them.
  • Change coupling: BrowserDownloadEntity.java ↔ JsonHelper.java app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java:1 — `app/src/main/java/com/solarized/firedown/data/entity/BrowserDownloadEntity.java` and `app/src/main/java/com/solarized/firedown/utils/JsonHelper.java` change together 55% of the time (6 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `835cfdcd` Capture: absorbed redirect targets, folded files, refined copies, lat…; `4d908b00` Captured: fix the clip names and duplicates the second device audit f…; `2512932a` YouTube: audio track selection in the download quality sheet — run `git show` on any of them.
  • Change coupling: MimeTypeThumbnail.java ↔ ProgressOverlayView.java app/src/main/java/com/solarized/firedown/glide/MimeTypeThumbnail.java:1 — `app/src/main/java/com/solarized/firedown/glide/MimeTypeThumbnail.java` and `app/src/main/java/com/solarized/firedown/ui/ProgressOverlayView.java` change together 50% of the time (6 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `f8bbcc4d` Mime placeholder ground IS the selection wash, in every list and grid; `45cf3f7d` Placeholder ⋮ survives the selection rebind; deepen the light ground; `7c2980c5` Mime fallback tile: per-theme ground, caption ink follows the tile — run `git show` on any of them.
  • Change coupling: DownloadsActivity.java ↔ P2pSendFragment.java app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java:1 — `app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java` change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 5 shared commits counted here, the most recent 3 are `3e6ca9b1` Send directly: route a link into the open Receive screen; never drop …; `04d22169` P2P share: TURN row router icon + review fixes (clipboard focus timing); `95ef1cfd` P2P share: remote-first flow — link is the hero, the reply is tappable — run `git show` on any of them.
  • Change coupling: AutoCompleteSearch.java ↔ WebHistoryDao.java app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:1 — `app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java` and `app/src/main/java/com/solarized/firedown/data/dao/WebHistoryDao.java` change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 5 shared commits counted here, the most recent 3 are `44766acd` History: a visit never erases a page's favicon (most-visited tile flip); `26a5a278` Most-visited removal: Chromium/Brave "Top Sites" blocklist (hide, kee…; `a8f2fa46` Most-visited: one row per host + drop blank-title rows, latest-visit … — run `git show` on any of them.
D4 · Code Duplication · Edited copy of a member (16 corresponding lines) · ×8
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java:54 — app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java:54-69 | app/src/main/java/com/solarized/firedown/sync/crypto/VaultCrypto.java:156-175 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:612 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:612-627 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:744-762 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:187 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:187-202 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:44-64 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:165 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:165-187 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:206-221 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/data/SingleLiveEvent.java:31 — app/src/main/java/com/solarized/firedown/data/SingleLiveEvent.java:31-46 | app/src/main/java/com/solarized/firedown/data/SingleLiveMediatorEvent.java:31-46 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/UpdateNotification.java:147 — app/src/main/java/com/solarized/firedown/UpdateNotification.java:147-162 | app/src/main/java/com/solarized/firedown/addons/AddonUpdateNotification.java:105-123 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:159 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:159-174 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:656-684 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1446 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1446-1461 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1503-1519 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (15 corresponding lines) · ×8
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:160 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:160-174 | app/src/main/java/com/solarized/firedown/phone/dialogs/SaveFileDialog.java:113-128 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:412 — app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:412-426 | app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:437-451 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:555 — app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:555-569 | app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:584-600 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:131 — app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:131-145 | REDACTED:621-635 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/data/models/WebBookmarkViewModel.java:123 — app/src/main/java/com/solarized/firedown/data/models/WebBookmarkViewModel.java:123-139 | app/src/main/java/com/solarized/firedown/data/models/WebHistoryViewModel.java:120-134 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:683 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:683-697 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1285-1299 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:634 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:634-656 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:458-472 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:842 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:842-856 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:893-907 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (8 corresponding lines) · ×8
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:334 — app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:334-341 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:220-227 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:186 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:186-193 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:179-186 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoError.java:243 — app/src/main/java/com/solarized/firedown/geckoview/GeckoError.java:243-250 | app/src/main/java/com/solarized/firedown/utils/Utils.java:100-107 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:155 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:155-162 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:196-203 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:352 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:352-361 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:80-87 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1702 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1702-1709 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:261-268 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:69 — scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:69-77 | scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:80-87 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) REDACTED:632 — REDACTED:632-639 | REDACTED:1205-1212 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (2.9 · ×7
  • Low contrast colour pair in CSS (2.9:1) design/home-card-border-options.html:15 — `.optlbl .pill` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-card-border-options.html:49 — `.cta` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-incognito-minimal.html:32 — `.badge` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-minimal-final.html:25 — `.badge` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-minimal.html:49 — `.badge` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-onboarding-borderless.html:29 — `.cta` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.9:1) design/home-onboarding-final.html:36 — `.cta` sets color: #fff on background-color: #f0716c — 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
D4 · Code Duplication · Edited copy of a member (17 corresponding lines) · ×7
  • Edited copy of a member (17 corresponding lines) app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java:35 — app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java:35-51 | app/src/main/java/com/solarized/firedown/sync/crypto/VaultCrypto.java:135-153 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:105 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:105-121 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewModel.java:129-146 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:303 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:303-320 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:179-195 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:894 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:894-910 | app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:198-215 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) app/src/main/java/com/solarized/firedown/GlideHelper.java:589 — app/src/main/java/com/solarized/firedown/GlideHelper.java:589-605 | app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:639-658 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) REDACTED:494 — REDACTED:494-513 | REDACTED:942-958 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) REDACTED:637 — REDACTED:637-653 | scripts/webdav-harness/src/com/solarized/firedown/sync/FakeDav.java:396-414 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
R10 · Code Duplication · Duplicated block (5 lines × 2 locations) · ×7
  • Duplicated block (5 lines × 2 locations) REDACTED:1602 — REDACTED:1602 · REDACTED:1668 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2 locations) REDACTED:1526 — REDACTED:1526 · REDACTED:1539 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (5 lines × 2 locations) REDACTED:1787 — REDACTED:1787 · REDACTED:1908 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (5 lines × 2 locations) REDACTED:972 — REDACTED:972 · REDACTED:1718 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2 locations) REDACTED:1052 — REDACTED:1052 · REDACTED:1065 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2 locations) REDACTED:1249 — REDACTED:1249 · REDACTED:2510 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2 locations) REDACTED:1334 — REDACTED:1334 · REDACTED:1339 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Edited copy of a member (14 corresponding lines) · ×6
  • Edited copy of a member (14 corresponding lines) app/src/main/java/com/solarized/firedown/okhttp/OriginInterceptor.java:59 — app/src/main/java/com/solarized/firedown/okhttp/OriginInterceptor.java:59-72 | app/src/main/java/com/solarized/firedown/utils/BrowserHeaders.java:121-137 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:305 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:305-327 | app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:337-350 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1256 — app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1256-1272 | app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1275-1288 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:325 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:325-339 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pShareBaseFragment.java:230-243 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:139 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:139-158 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:54-67 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) scripts/backup-fault-harness/mutants.py:75 — scripts/backup-fault-harness/mutants.py:75-88 | scripts/s3-harness/mutants.py:100-113 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (16 lines × 2) · ×6
  • Duplicated block (16 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:474 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:474-489 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:127-142 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (16 lines × 2) REDACTED:1263 — REDACTED:1263-1278 | REDACTED:809-824 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (16 lines × 2) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:163 — app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:163-178 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:242-257 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:163` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (16 lines × 2) REDACTED:1133 — REDACTED:1133-1148 | REDACTED:580-595 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (16 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:357 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:357-372 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:89-104 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 63 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:357` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) REDACTED:668 — REDACTED:668-683 | REDACTED:1206-1221 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `REDACTED:684` calls `clear` and `REDACTED:1222` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (13 lines × 2) · ×6
  • Duplicated block (13 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:125 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:125-137 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:198-210 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:106 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:106-118 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:118-130 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java` and `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 66 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:106` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:137` calls `setFileResolution`, `probeImageResolution`, `getAbsolutePath` and `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:120` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (13 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:424 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:424-436 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:292-304 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java` and `app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 55 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:424` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) REDACTED:1248 — REDACTED:1248-1260 | REDACTED:794-806 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1248` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:715 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:715-727 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:790-802 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:715` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:398 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:398-410 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:342-354 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:398` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (5 lines × 3) · ×6
  • Duplicated block (5 lines × 3) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:131 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:131-135 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:173-177 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:142-146 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart.
  • Duplicated block (5 lines × 3) app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomNavigationBar.java:286 — app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomNavigationBar.java:286-294 | app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomProgressView.java:108-118 | app/src/main/java/com/solarized/firedown/settings/ShareAppFragment.java:69-73 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomNavigationBar.java:286` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (5 lines × 3) app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:52 — app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:52-56 | app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:137-141 | app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:93-98 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java` and `app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:93` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (5 lines × 3) app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:69 — app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:69-73 | app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:87-91 | app/src/main/java/com/solarized/firedown/sync/model/VaultManifest.java:68-72 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:69` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 3) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:960 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:960-967 | app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:417-423 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:673-677 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
  • Duplicated block (5 lines × 3) REDACTED:238 — REDACTED:238-242 | REDACTED:176-180 | REDACTED:171-175 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D6 · Cohesion (LCOM4) · Low cohesion · ×6
  • Low cohesion: DownloadFragment (LCOM4 8) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:84 — DownloadFragment's methods fall into 8 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 8 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: Reply (LCOM4 7) REDACTED:87 — Reply's methods fall into 7 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 7 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: S3Client (LCOM4 5) REDACTED:86 — S3Client's methods fall into 5 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 5 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: GeckoComponents (LCOM4 4) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:79 — GeckoComponents's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: SettingsFragment (LCOM4 4) app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:61 — SettingsFragment's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: LCEERecyclerView (LCOM4 4) app/src/main/java/com/solarized/firedown/ui/LCEERecyclerView.java:26 — LCEERecyclerView's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
AC6 · Visual & motion safety · Animation without a prefers-reduced-motion guard · ×5
  • Animation without a prefers-reduced-motion guard sketches/home-ember-tuner.html:39 — `.breathing .glow` moves (`animation: breathe var(--speed,2.6s) ease-in-out infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
  • Animation without a prefers-reduced-motion guard sketches/home-slickness-directions.html:71 — `.active-dl .ember` moves (`animation: breathe 2.4s ease-in-out infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
  • Animation without a prefers-reduced-motion guard sketches/home-slickness-directions.html:78 — `.flare .ember` moves (`animation: flare .9s ease-out 1`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
  • Animation without a prefers-reduced-motion guard sketches/home-slickness-directions.html:83 — `.flare .pop` moves (`animation: pop .9s ease-out 1`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
  • Animation without a prefers-reduced-motion guard sketches/home-slickness-directions.html:88 — `.mini-spin` moves (`animation: spin .8s linear infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
D4 · Code Duplication · Members sharing a duplicated core (4 members, 50+ identical tokens) · ×5
  • Members sharing a duplicated core (4 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/UpdateNotification.java:24 — app/src/main/java/com/solarized/firedown/UpdateNotification.java:24-44 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:46-69 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:115-139 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:169-207 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1272 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1272-1294 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1491-1554 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1666-1676 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1723-1733 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:35 — app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:35-112 | app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:61-259 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:67-213 | app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:70-122 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:141 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:141-175 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pShareBaseFragment.java:71-89 | app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:201-233 | app/src/main/java/com/solarized/firedown/phone/fragments/StorageReviewFragment.java:128-189 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/settings/AddonOptionsFragment.java:57 — app/src/main/java/com/solarized/firedown/settings/AddonOptionsFragment.java:57-89 | app/src/main/java/com/solarized/firedown/settings/FeedbackFragment.java:87-110 | app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:123-184 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:93-139 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
D4 · Code Duplication · Edited copy of a member (23 corresponding lines) · ×5
  • Edited copy of a member (23 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:414 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:414-436 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:282-304 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:111 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:111-133 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:177-211 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:145 — app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:145-175 | app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:178-200 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:675 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:675-697 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:549-571 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) app/src/main/java/com/solarized/firedown/glide/DownloadEntityModelLoader.java:71 — app/src/main/java/com/solarized/firedown/glide/DownloadEntityModelLoader.java:71-94 | app/src/main/java/com/solarized/firedown/glide/DownloadEntityUriModelLoader.java:66-88 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (18 corresponding lines) · ×5
  • Edited copy of a member (18 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:582 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:582-599 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:415-439 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:136 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:136-153 | app/src/main/java/com/solarized/firedown/phone/dialogs/SaveFileDialog.java:216-233 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) app/src/main/java/com/solarized/firedown/addons/AddonUpdateReviews.java:103 — app/src/main/java/com/solarized/firedown/addons/AddonUpdateReviews.java:103-126 | app/src/main/java/com/solarized/firedown/addons/AddonUpdateReviews.java:132-149 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) app/src/main/java/com/solarized/firedown/data/DownloadBackupMirror.java:293 — app/src/main/java/com/solarized/firedown/data/DownloadBackupMirror.java:293-310 | REDACTED:221-244 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1411 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1411-1428 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1479-1496 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
R10 · Code Duplication · Duplicated block (8 lines × 2 locations) · ×5
  • Duplicated block (8 lines × 2 locations) REDACTED:1206 — REDACTED:1206 · REDACTED:1214 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (8 lines × 2 locations) scripts/p2pshare-smoke.mjs:653 — scripts/p2pshare-smoke.mjs:653 · scripts/p2pshare-smoke.mjs:671 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (8 lines × 2 locations) REDACTED:2252 — REDACTED:2252 · REDACTED:2592 — all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
  • Duplicated block (8 lines × 2 locations) REDACTED:2545 — REDACTED:2545 · REDACTED:2559 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2 locations) scripts/youtube-pip-smoke.mjs:138 — scripts/youtube-pip-smoke.mjs:138 · scripts/youtube-webcompat-smoke.mjs:212 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
AC3 · Page structure · Heading level jumps from h1 to h3 · ×4
  • Heading level jumps from h1 to h3 design/home-minimal.html:80 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h1 to h3 design/home-mockups-minimal.html:126 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h1 to h3 design/home-onboarding-zero.html:162 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h1 to h3 design/home-stats-alternatives.html:52 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
AC3 · Page structure · Heading level jumps from h2 to h4 · ×4
  • Heading level jumps from h2 to h4 sketches/bookmark-edit-improvements.html:429 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h2 to h4 sketches/bookmark-edit-improvements.html:475 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h2 to h4 sketches/bookmark-edit-improvements.html:549 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h2 to h4 sketches/browsesubtitleunified.html:682 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
D4 · Code Duplication · Edited copy of a member (21 corresponding lines) · ×4
  • Edited copy of a member (21 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:324 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:324-344 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:199-220 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:120 — app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:120-140 | app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkEditFragment.java:226-253 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:583 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:583-604 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:606-626 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:77 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:77-97 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:100-120 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (20 corresponding lines) · ×4
  • Edited copy of a member (20 corresponding lines) app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:272 — app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:272-293 | app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:323-342 — These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:226 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:226-256 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:336-355 — These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1433 — app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1433-1453 | app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1464-1483 — These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1065 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1065-1091 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1104-1123 — These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
X3 · Exception handling · Swallowed exception (empty catch) · ×4
  • Swallowed exception (empty catch) app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:390 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:407 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:503 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:2445 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (2.8 · ×3
  • Low contrast colour pair in CSS (2.8:1) design/home-minimal.html:13 — `.tag` sets color: #fff on background-color: #9a98a6 — 2.8:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.8:1) design/home-stats-alternatives.html:13 — `.tag` sets color: #fff on background-color: #9a98a6 — 2.8:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.8:1) design/home-subtitle-options.html:20 — `.tag` sets color: #fff on background-color: #9a98a6 — 2.8:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
D17 · Explicit Debt · TodoComment · ×3
  • TodoComment app/src/main/java/com/solarized/firedown/utils/WebUtils.java:285 — // TODO Auto-generated catch block — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment app/src/main/java/com/solarized/firedown/manager/RunnableManager.java:300 — // TODO: Consider calling — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment app/src/main/java/com/solarized/firedown/glide/svg/SvgDecoder.java:25 — // TODO: Can we tell? — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
D29 · Static Analysis (SAST) · REDACTED · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Edited copy of a member (25 corresponding lines) · ×3
  • Edited copy of a member (25 corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:569 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:569-597 | app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:586-610 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1024 — app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1024-1048 | app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1051-1083 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1424 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1424-1448 | app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1470-1496 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (22 corresponding lines) · ×3
  • Edited copy of a member (22 corresponding lines) app/src/main/java/com/solarized/firedown/GlideHelper.java:198 — app/src/main/java/com/solarized/firedown/GlideHelper.java:198-223 | app/src/main/java/com/solarized/firedown/GlideHelper.java:235-256 — These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:966 — app/src/main/java/com/solarized/firedown/addons/AddonManager.java:966-987 | app/src/main/java/com/solarized/firedown/addons/AddonManager.java:994-1022 — These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) REDACTED:581 — REDACTED:581-608 | REDACTED:1011-1032 — These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (4 corresponding lines) · ×3
  • Edited copy of a member (4 corresponding lines) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:657 — app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:657-660 | scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4Fixtures.java:235-238 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:198 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:198-201 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:560-563 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:89 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:89-92 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:71-74 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 11+ corresponding lines) · ×3
  • Edited copies of one member (4 members, 11+ corresponding lines) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:412 — app/src/main/java/com/solarized/firedown/UpdateDownloader.java:412-422 | app/src/main/java/com/solarized/firedown/UpdateScheduler.java:30-60 | app/src/main/java/com/solarized/firedown/UpdateScheduler.java:75-91 | app/src/main/java/com/solarized/firedown/UpdateScheduler.java:93-107 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
  • Edited copies of one member (4 members, 11+ corresponding lines) app/src/main/java/com/solarized/firedown/utils/DateOrganizer.java:71 — app/src/main/java/com/solarized/firedown/utils/DateOrganizer.java:71-81 | app/src/main/java/com/solarized/firedown/utils/DateOrganizer.java:83-94 | app/src/main/java/com/solarized/firedown/utils/DateOrganizer.java:96-108 | app/src/main/java/com/solarized/firedown/utils/DateOrganizer.java:110-121 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
  • Edited copies of one member (4 members, 11+ corresponding lines) scripts/sessions-harness/splice.py:37 — scripts/sessions-harness/splice.py:37-48 | scripts/sessions-harness/splice.py:52-63 | scripts/visit-harness/splice.py:30-41 | scripts/visit-harness/splice.py:45-55 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (22 lines × 2) · ×3
  • Duplicated block (22 lines × 2) app/src/main/java/com/solarized/firedown/GlideHelper.java:651 — app/src/main/java/com/solarized/firedown/GlideHelper.java:651-672 | app/src/main/java/com/solarized/firedown/GlideHelper.java:810-831 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/GlideHelper.java:651` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (22 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:114 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:114-135 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:156-177 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (22 lines × 2) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:174 — app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:174-195 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:216-237 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:174` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14 lines × 2) · ×3
  • Duplicated block (14 lines × 2) app/src/main/java/com/solarized/firedown/data/SingleLiveEvent.java:33 — app/src/main/java/com/solarized/firedown/data/SingleLiveEvent.java:33-46 | app/src/main/java/com/solarized/firedown/data/SingleLiveMediatorEvent.java:33-46 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/SingleLiveEvent.java` and `app/src/main/java/com/solarized/firedown/data/SingleLiveMediatorEvent.java` as WHOLE FILES: 95% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 1 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (14 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:109 — app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:109-122 | app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:163-176 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:82 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:82-95 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegGifMaker.java:88-101 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEncoder.java:82` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (10 lines × 3) · ×3
  • Duplicated block (10 lines × 3) REDACTED:275 — REDACTED:275-284 | REDACTED:284-293 | REDACTED:179-188 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:275` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) app/src/main/java/com/solarized/firedown/sync/FolderStore.java:861 — app/src/main/java/com/solarized/firedown/sync/FolderStore.java:861-870 | REDACTED:1243-1252 | REDACTED:789-798 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sync/FolderStore.java:861` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) REDACTED:412 — REDACTED:412-421 | REDACTED:1194-1203 | REDACTED:621-630 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (8 lines × 3) · ×3
  • Duplicated block (8 lines × 3) app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:217 — app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:217-224 | app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:602-609 | app/src/main/java/com/solarized/firedown/manager/TimedTextStrategy.java:198-205 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
  • Duplicated block (8 lines × 3) app/src/main/java/com/solarized/firedown/phone/dialogs/CertDialogFragment.java:47 — app/src/main/java/com/solarized/firedown/phone/dialogs/CertDialogFragment.java:47-54 | app/src/main/java/com/solarized/firedown/phone/dialogs/InfoBottomSheetDialogFragment.java:51-58 | app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:121-128 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
  • Duplicated block (8 lines × 3) REDACTED:177 — REDACTED:177-184 | REDACTED:152-159 | REDACTED:113-120 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
PF3 · Async & latency hygiene · Sync-over-async blocking · ×3
  • Sync-over-async blocking scripts/consent-harness.mjs:70 — `readFileSync` in `fetch` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking scripts/load-playwright.mjs:65 — `existsSync` in `find` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking scripts/load-playwright.mjs:71 — `existsSync` in `find` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
R10 · Code Duplication · Duplicated block (9 lines × 2 locations) · ×3
  • Duplicated block (9 lines × 2 locations) scripts/p2pshare-smoke.mjs:405 — scripts/p2pshare-smoke.mjs:405 · scripts/p2pshare-smoke.mjs:418 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (9 lines × 2 locations) scripts/p2pshare-smoke.mjs:585 — scripts/p2pshare-smoke.mjs:585 · scripts/p2pshare-smoke.mjs:597 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (9 lines × 2 locations) REDACTED:1760 — REDACTED:1760 · REDACTED:1769 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R10 · Code Duplication · Duplicated block (6 lines × 2 locations) · ×3
  • Duplicated block (6 lines × 2 locations) scripts/p2pshare-smoke.mjs:105 — scripts/p2pshare-smoke.mjs:105 · scripts/p2pshare-smoke.mjs:118 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (6 lines × 2 locations) REDACTED:1649 — REDACTED:1649 · REDACTED:1846 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (6 lines × 2 locations) REDACTED:1260 — REDACTED:1260 · REDACTED:1279 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R10 · Code Duplication · Duplicated block (5 lines × 3 locations) · ×3
  • Duplicated block (5 lines × 3 locations) scripts/dailymotion-replay.mjs:72 — scripts/dailymotion-replay.mjs:72 · scripts/live-canary.mjs:81 · REDACTED:56 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (5 lines × 3 locations) REDACTED:1651 — REDACTED:1651 · REDACTED:1670 · REDACTED:1811 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 3 locations) REDACTED:1660 — REDACTED:1660 · REDACTED:1745 · REDACTED:1878 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
AC3 · Page structure · Heading level jumps from h1 to h4 · ×2
  • Heading level jumps from h1 to h4 design/home-mockups.html:206 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
  • Heading level jumps from h1 to h4 sketches/addons.html:139 — Skipping heading levels breaks the document outline assistive tech relies on. Don't jump levels — increase by at most one.
AC4 · Keyboard semantics · Anchor without href · ×2
  • Anchor without href design/home-mockups.html:213 — An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
  • Anchor without href design/home-mockups.html:245 — An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (3.1 · ×2
  • Low contrast colour pair in CSS (3.1:1) design/home-onboarding-zero.html:34 — `.cap .tag` sets color: #fff on background-color: #FF5A1F — 3.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (3.1:1) design/home-onboarding-zero.html:81 — `.cta` sets color: #fff on background-color: #FF5A1F — 3.1:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (2.7 · ×2
  • Low contrast colour pair in CSS (2.7:1) design/home-onboarding-zero.html:73 — `.step .n` sets color: #FF5A1F on background-color: #FFEDE5 — 2.7:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.7:1) sketches/bookmarks-card-sketches.html:134 — `.fav.mz` sets color: #fff on background-color: #ff7139 — 2.7:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
D2 · Cognitive Complexity · page-state-bridge.collectPlayableMedia · ×2
  • page-state-bridge.collectPlayableMedia::walkNode (cognitive 89) app/src/main/assets/webrequests/js/page-state-bridge.js:1360 — page-state-bridge.collectPlayableMedia::walkNode has cognitive complexity 89 (threshold 15). Drivers by points: if/else 19 (48 pts), error handling 8 (21 pts), loops 6 (11 pts), boolean chains 9 (nesting depth added 47). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: 2 other methods here (page-state-bridge.collectPlayableMedia, page-state-bridge.collectPlayableMedia::fillMeta) have the same decision points, in the same order, at the same nesting depths — so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
  • page-state-bridge.collectPlayableMedia::fillMeta (cognitive 20) app/src/main/assets/webrequests/js/page-state-bridge.js:1321 — page-state-bridge.collectPlayableMedia::fillMeta has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: 2 other methods here (page-state-bridge.collectPlayableMedia, page-state-bridge.collectPlayableMedia::walkNode) have the same decision points, in the same order, at the same nesting depths — so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · NavigationUtils.navigateSafe (cognitive 23) · ×2
  • NavigationUtils.navigateSafe (cognitive 23) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:69 — NavigationUtils.navigateSafe has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (NavigationUtils.navigateSafe) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
  • NavigationUtils.navigateSafe (cognitive 23) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:198 — NavigationUtils.navigateSafe has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (NavigationUtils.navigateSafe) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · NavigationUtils.navigateSafe (cognitive 21) · ×2
  • NavigationUtils.navigateSafe (cognitive 21) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:161 — NavigationUtils.navigateSafe has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (NavigationUtils.navigateSafe) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
  • NavigationUtils.navigateSafe (cognitive 21) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:240 — NavigationUtils.navigateSafe has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (NavigationUtils.navigateSafe) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · 1.onCreateMenu (cognitive 17) · ×2
  • 1.onCreateMenu (cognitive 17) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:371 — 1.onCreateMenu has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), ternaries 2 (6 pts), loops 1 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • 1.onCreateMenu (cognitive 17) app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:103 — 1.onCreateMenu has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), ternaries 2 (6 pts), loops 1 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D29 · Static Analysis (SAST) · REDACTED · ×2
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×2
  • REDACTED
  • REDACTED
D4 · Code Duplication · Edited copy of a member (31 corresponding lines) · ×2
  • Edited copy of a member (31 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:548 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:548-590 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:284-318 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (31 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:136 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:136-166 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:214-249 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (36 corresponding lines) · ×2
  • Edited copy of a member (36 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:356 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:356-391 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:88-124 — These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (36 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:592 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:592-648 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:237-272 — These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (33 corresponding lines) · ×2
  • Edited copy of a member (33 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:649 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:649-681 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1108-1162 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (33 corresponding lines) app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:41 — app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:41-73 | app/src/main/java/com/solarized/firedown/glide/svg/SvgUriDecoder.java:43-77 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (24 corresponding lines) · ×2
  • Edited copy of a member (24 corresponding lines) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:446 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:446-473 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:475-498 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/media/GeckoMediaController.java:168 — app/src/main/java/com/solarized/firedown/geckoview/media/GeckoMediaController.java:168-196 | app/src/main/java/com/solarized/firedown/geckoview/media/GeckoMediaController.java:202-225 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (27 corresponding lines) · ×2
  • Edited copy of a member (27 corresponding lines) app/src/main/java/com/solarized/firedown/data/models/TabsArchiveViewModel.java:92 — app/src/main/java/com/solarized/firedown/data/models/TabsArchiveViewModel.java:92-118 | app/src/main/java/com/solarized/firedown/data/models/WebHistoryViewModel.java:87-115 — These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (27 corresponding lines) REDACTED:460 — REDACTED:460-492 | REDACTED:914-940 — These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 14+ corresponding lines) · ×2
  • Edited copies of one member (4 members, 14+ corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/BrowserTabsAdapter.java:472 — app/src/main/java/com/solarized/firedown/ui/adapters/BrowserTabsAdapter.java:472-487 | app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:175-188 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:217-230 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:237-250 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
  • Edited copies of one member (4 members, 14+ corresponding lines) app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:171 — app/src/main/java/com/solarized/firedown/addons/AmoCatalogClient.java:171-187 | app/src/main/java/com/solarized/firedown/addons/XpiManifest.java:194-210 | app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:487-500 | app/src/main/java/com/solarized/firedown/sync/BackupLayout.java:266-279 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 8+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 8+ corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserContentDialogFragment.java:109 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserContentDialogFragment.java:109-119 | app/src/main/java/com/solarized/firedown/phone/dialogs/RenameFileDialog.java:55-63 | app/src/main/java/com/solarized/firedown/phone/dialogs/SaveFileDialog.java:57-64 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 8+ corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:647 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:647-654 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:679-687 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:801-810 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 12+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 12+ corresponding lines) app/src/main/java/com/solarized/firedown/ui/adapters/InfoAdapter.java:100 — app/src/main/java/com/solarized/firedown/ui/adapters/InfoAdapter.java:100-111 | app/src/main/java/com/solarized/firedown/ui/adapters/SearchAutocompleteAdapter.java:136-147 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:100-111 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 12+ corresponding lines) app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:90 — app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:90-101 | app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:104-116 | app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:119-131 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 6+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 6+ corresponding lines) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:343 — app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:343-348 | app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:618-628 | app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:229-234 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 6+ corresponding lines) app/src/main/java/com/solarized/firedown/ui/diffs/GeckoStateDiffCallback.java:25 — app/src/main/java/com/solarized/firedown/ui/diffs/GeckoStateDiffCallback.java:25-31 | app/src/main/java/com/solarized/firedown/ui/diffs/SearchDiffCallback.java:17-22 | app/src/main/java/com/solarized/firedown/ui/diffs/WebBookmarkDiffCallback.java:17-22 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 11+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 11+ corresponding lines) app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:215 — app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:215-226 | app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:958-968 | app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java:986-996 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 11+ corresponding lines) app/src/main/java/com/solarized/firedown/ui/diffs/DownloadDiffCallback.java:14 — app/src/main/java/com/solarized/firedown/ui/diffs/DownloadDiffCallback.java:14-26 | app/src/main/java/com/solarized/firedown/ui/diffs/TabStateArchivedDiffCallback.java:14-24 | app/src/main/java/com/solarized/firedown/ui/diffs/WebHistoryDiffCallback.java:14-26 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 10+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 10+ corresponding lines) app/src/main/java/com/solarized/firedown/App.java:422 — app/src/main/java/com/solarized/firedown/App.java:422-437 | app/src/main/java/com/solarized/firedown/App.java:440-449 | app/src/main/java/com/solarized/firedown/App.java:451-460 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 10+ corresponding lines) scripts/datauri-harness/src/DataUrisHarness.java:18 — scripts/datauri-harness/src/DataUrisHarness.java:18-27 | scripts/donation-harness/src/DonationPromptHarness.java:20-29 | scripts/player-subtitles-harness/src/PlayerSubtitlesHarness.java:23-32 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (5 corresponding lines) · ×2
  • Edited copy of a member (5 corresponding lines) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:660 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:660-664 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:328-332 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:142 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:142-146 | scripts/engine-harness/src/com/solarized/firedown/harness/EngineStress.java:238-242 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (18 lines × 2) · ×2
  • Duplicated block (18 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:78 — app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:78-95 | app/src/main/java/com/solarized/firedown/manager/tasks/OutSafeTask.java:77-94 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (18 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:584 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:584-601 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:607-624 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:602` calls `setAnchorView` and `app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:625` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (16–17 lines × 2) · ×2
  • Duplicated block (16–17 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:376 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:376-391 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:108-124 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 63 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:376` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16–17 lines × 2) app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:103 — app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:103-118 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:471-487 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java` and `app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:103` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:469` calls `d` and `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:101` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (17 lines × 2) · ×2
  • Duplicated block (17 lines × 2) REDACTED:1223 — REDACTED:1223-1239 | REDACTED:769-785 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (17 lines × 2) app/src/main/java/com/solarized/firedown/ui/browser/BookmarkBrowserButton.java:13 — app/src/main/java/com/solarized/firedown/ui/browser/BookmarkBrowserButton.java:13-33 | app/src/main/java/com/solarized/firedown/ui/browser/ForwardBrowserButton.java:13-29 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (15 lines × 2) · ×2
  • Duplicated block (15 lines × 2) app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:132 — app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java:132-146 | app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:283-297 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/FFmpegMergeStrategy.java` and `app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (15 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:207 — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:207-221 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:147-161 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java` and `app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 55 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (12–13 lines × 2) · ×2
  • Duplicated block (12–13 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:683 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:683-694 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:557-569 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:695` calls `d` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:570` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12–13 lines × 2) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:461 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:461-473 | app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:487-498 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:461` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (11 lines × 3) · ×2
  • Duplicated block (11 lines × 3) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:43 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:43-54 | app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java:53-63 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:43-54 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java` and `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 66 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:43` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) scripts/backup-fault-harness/mutants.py:78 — scripts/backup-fault-harness/mutants.py:78-88 | scripts/backup-sim-harness/mutants.py:94-104 | scripts/s3-harness/mutants.py:103-113 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (9–10 lines × 2) · ×2
  • Duplicated block (9–10 lines × 2) app/src/main/java/com/solarized/firedown/addons/AddonPermissions.java:301 — app/src/main/java/com/solarized/firedown/addons/AddonPermissions.java:301-310 | app/src/main/java/com/solarized/firedown/geckoview/SitePermissions.java:187-195 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (9–10 lines × 2) app/src/main/java/com/solarized/firedown/phone/dialogs/PlaybackSpeedSheetDialogFragment.java:98 — app/src/main/java/com/solarized/firedown/phone/dialogs/PlaybackSpeedSheetDialogFragment.java:98-106 | app/src/main/java/com/solarized/firedown/phone/dialogs/SubtitleSheetDialogFragment.java:129-138 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (8–9 lines × 3) · ×2
  • Duplicated block (8–9 lines × 3) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:128 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:128-135 | app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java:156-164 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:149-157 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java` and `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 66 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:128` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:121` calls `publishIfEnabled`, `getFilePath`, `getFileMimeType` and `app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java:149` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8–9 lines × 3) app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:146 — app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:146-153 | app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:185-193 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:88-96 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:146` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–9 lines × 2) · ×2
  • Duplicated block (8–9 lines × 2) app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:109 — app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:109-117 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectViewModel.java:88-95 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/settings/S3ConnectViewModel.java:109` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8–9 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1295 — app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1295-1302 | app/src/main/java/com/solarized/firedown/ui/adapters/StorageReviewAdapter.java:228-236 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1295` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `holder` to `DownloadViewHolder` in one and `Holder` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (6–8 lines × 3) · ×2
  • Duplicated block (6–8 lines × 3) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1278 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1278-1285 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1668-1673 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1725-1730 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1668` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6–8 lines × 3) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3425 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3425-3430 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:743-749 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:510-517 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3425` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (6 lines × 3) · ×2
  • Duplicated block (6 lines × 3) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:903 — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:903-908 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:370-376 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:309-315 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:903` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) REDACTED:885 — REDACTED:885-890 | REDACTED:899-904 | REDACTED:913-918 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:885` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (5 lines × 4) · ×2
  • Duplicated block (5 lines × 4) app/src/main/java/com/solarized/firedown/UpdateNotification.java:30 — app/src/main/java/com/solarized/firedown/UpdateNotification.java:30-34 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:55-59 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:129-133 | app/src/main/java/com/solarized/firedown/UpdateNotification.java:187-193 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/UpdateNotification.java:187` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 4) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1278 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1278-1285 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1523-1530 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1668-1672 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1725-1729 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Edited copies of one member (3 members, 18+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 18+ corresponding lines) scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:746 — scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:746-763 | scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:765-782 | scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:800-819 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 18+ corresponding lines) REDACTED:304 — REDACTED:304-321 | REDACTED:605-623 | REDACTED:128-146 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (9 lines × 3) · ×2
  • Duplicated block (9 lines × 3) scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:44 — scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:44-52 | scripts/sessions-harness/src/com/solarized/firedown/harness/SessionsHarness.java:134-142 | scripts/thumb-harness/src/com/solarized/firedown/harness/ThumbHarness.java:57-65 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:44` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:1279 — scripts/update-harness/flow/src/com/solarized/firedown/UpdateFlowHarness.java:1279-1287 | REDACTED:49-57 | scripts/update-harness/src/com/solarized/firedown/update/UpdateFuzz.java:40-48 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
D4 · Code Duplication · Duplicated block (7 lines × 3) · ×2
  • Duplicated block (7 lines × 3) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:551 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:551-557 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:581-587 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:598-604 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:580` calls `putExtra` and `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:597` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) REDACTED:244 — REDACTED:244-250 | REDACTED:182-188 | REDACTED:177-183 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
R10 · Code Duplication · Duplicated block (12 lines × 2 locations) · ×2
  • Duplicated block (12 lines × 2 locations) scripts/icons-smoke.mjs:17 — scripts/icons-smoke.mjs:17 · scripts/p2pshare-smoke.mjs:16 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it.
  • Duplicated block (12 lines × 2 locations) scripts/instagram-replay.mjs:182 — scripts/instagram-replay.mjs:182 · scripts/instagram-replay.mjs:270 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (6 lines × 3 locations) · ×2
  • Duplicated block (6 lines × 3 locations) scripts/dailymotion-replay.mjs:226 — scripts/dailymotion-replay.mjs:226 · scripts/dailymotion-replay.mjs:261 · scripts/dailymotion-replay.mjs:329 — all 3 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
  • Duplicated block (6 lines × 3 locations) REDACTED:2519 — REDACTED:2519 · REDACTED:2545 · REDACTED:2559 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
AC6 · Visual & motion safety · Low contrast colour pair (4.4 · ×1
  • Low contrast colour pair (4.4:1) sketches/addons.html:467 — The inline foreground/background colours fall below the 4.5:1 WCAG AA minimum for normal text. Darken/lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (2.6 · ×1
  • Low contrast colour pair in CSS (2.6:1) sketches/bookmarks-card-sketches.html:133 — `.fav.so` sets color: #fff on background-color: #f48024 — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (4.0 · ×1
  • Low contrast colour pair in CSS (4.0:1) sketches/bookmarks-card-sketches.html:135 — `.fav.yt` sets color: #fff on background-color: #ff0000 — 4.0:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (3.6 · ×1
  • Low contrast colour pair in CSS (3.6:1) sketches/bookmarks-card-sketches.html:136 — `.fav.gn` sets color: #fff on background-color: #4285f4 — 3.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
AC6 · Visual & motion safety · Low contrast colour pair (2.9 · ×1
  • Low contrast colour pair (2.9:1) sketches/errorcolorpreview.html:114 — The inline foreground/background colours fall below the 4.5:1 WCAG AA minimum for normal text. Darken/lighten one of them.
D1 · Cyclomatic Complexity · background.processVideo (cyclomatic 133) · ×1
  • background.processVideo (cyclomatic 133) app/src/main/assets/youtube/background.js:1975 — background.processVideo has cyclomatic complexity 133 (threshold 15). Of this number, 129 points are the body's own statements and 4 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BrowserFragment.onViewCreated (cyclomatic 100) · ×1
  • BrowserFragment.onViewCreated (cyclomatic 100) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736 — BrowserFragment.onViewCreated has cyclomatic complexity 100 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · requests.emitCapture (cyclomatic 87) · ×1
  • requests.emitCapture (cyclomatic 87) app/src/main/assets/webrequests/js/requests.js:1027 — requests.emitCapture has cyclomatic complexity 87 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FileUriHelper.getFileExtensionFromMimeType (cyclomatic 64) · ×1
  • FileUriHelper.getFileExtensionFromMimeType (cyclomatic 64) app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:803 — FileUriHelper.getFileExtensionFromMimeType has cyclomatic complexity 64 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · facebook.findNodeStarts (cyclomatic 57) · ×1
  • facebook.findNodeStarts (cyclomatic 57) app/src/main/assets/webrequests/js/parsers/facebook.js:119 — facebook.findNodeStarts has cyclomatic complexity 57 (threshold 15). Of this number, 42 points are the body's own statements and 15 belong to 4 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FileUriHelper.getMimeTypeFromFile (cyclomatic 55) · ×1
  • FileUriHelper.getMimeTypeFromFile (cyclomatic 55) app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:551 — FileUriHelper.getMimeTypeFromFile has cyclomatic complexity 55 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.readVideoJs (cyclomatic 54) · ×1
  • page-state-bridge.readVideoJs (cyclomatic 54) app/src/main/assets/webrequests/js/page-state-bridge.js:814 — page-state-bridge.readVideoJs has cyclomatic complexity 54 (threshold 15). Of this number, 51 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · HttpDownloadStrategy.execute (cyclomatic 51) · ×1
  • HttpDownloadStrategy.execute (cyclomatic 51) app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:60 — HttpDownloadStrategy.execute has cyclomatic complexity 51 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · instagram.processFilteredInstagramResponse (cyclomatic 51) · ×1
  • instagram.processFilteredInstagramResponse (cyclomatic 51) app/src/main/assets/webrequests/js/parsers/instagram.js:797 — instagram.processFilteredInstagramResponse has cyclomatic complexity 51 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · M3U8Parser.parseMaster (cyclomatic 49) · ×1
  • M3U8Parser.parseMaster (cyclomatic 49) app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:97 — M3U8Parser.parseMaster has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · instagram.processInstagramFeedItems (cyclomatic 49) · ×1
  • instagram.processInstagramFeedItems (cyclomatic 49) app/src/main/assets/webrequests/js/parsers/instagram.js:1076 — instagram.processInstagramFeedItems has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.emitOneGroup (cyclomatic 48) · ×1
  • page-state-bridge.emitOneGroup (cyclomatic 48) app/src/main/assets/webrequests/js/page-state-bridge.js:1617 — page-state-bridge.emitOneGroup has cyclomatic complexity 48 (threshold 15). Of this number, 42 points are the body's own statements and 6 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · background.buildAdaptiveVariants (cyclomatic 47) · ×1
  • background.buildAdaptiveVariants (cyclomatic 47) app/src/main/assets/youtube/background.js:1561 — background.buildAdaptiveVariants has cyclomatic complexity 47 (threshold 15). Of this number, 43 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.collectPlayableMedia · ×1
  • page-state-bridge.collectPlayableMedia::walkNode (cyclomatic 45) app/src/main/assets/webrequests/js/page-state-bridge.js:1360 — page-state-bridge.collectPlayableMedia::walkNode has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (page-state-bridge.collectPlayableMedia) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D1 · Cyclomatic Complexity · requests.decideCapture (cyclomatic 45) · ×1
  • requests.decideCapture (cyclomatic 45) app/src/main/assets/webrequests/js/requests.js:702 — requests.decideCapture has cyclomatic complexity 45 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · tiktok.handleTikTokItemList (cyclomatic 44) · ×1
  • tiktok.handleTikTokItemList (cyclomatic 44) app/src/main/assets/webrequests/js/parsers/tiktok.js:305 — tiktok.handleTikTokItemList has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (tiktok.handleTikTokItemList::walk) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D1 · Cyclomatic Complexity · common.parseHlsMaster (cyclomatic 43) · ×1
  • common.parseHlsMaster (cyclomatic 43) app/src/main/assets/webrequests/js/parsers/common.js:282 — common.parseHlsMaster has cyclomatic complexity 43 (threshold 15). Of this number, 42 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · requests.browser.runtime.onMessage.addListener() (cyclomatic 42) · ×1
  • requests.browser.runtime.onMessage.addListener() (cyclomatic 42) app/src/main/assets/webrequests/js/requests.js:2502 — requests.browser.runtime.onMessage.addListener() has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.readDomMedia (cyclomatic 41) · ×1
  • page-state-bridge.readDomMedia (cyclomatic 41) app/src/main/assets/webrequests/js/page-state-bridge.js:664 — page-state-bridge.readDomMedia has cyclomatic complexity 41 (threshold 15). Of this number, 32 points are the body's own statements and 9 belong to one function item inside it that branches. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · SabrDownloader.download (cyclomatic 40) · ×1
  • SabrDownloader.download (cyclomatic 40) app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:278 — SabrDownloader.download has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · SabrMessages.buildAbrRequest (cyclomatic 40) · ×1
  • SabrMessages.buildAbrRequest (cyclomatic 40) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:551 — SabrMessages.buildAbrRequest has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · background.fetchTvHtml5Stream (cyclomatic 40) · ×1
  • background.fetchTvHtml5Stream (cyclomatic 40) app/src/main/assets/youtube/background.js:1095 — background.fetchTvHtml5Stream has cyclomatic complexity 40 (threshold 15). Of this number, 39 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FFmpegMetaDataReader.getMimeType (cyclomatic 38) · ×1
  • FFmpegMetaDataReader.getMimeType (cyclomatic 38) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:389 — FFmpegMetaDataReader.getMimeType has cyclomatic complexity 38 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.fetchMediaList (cyclomatic 38) · ×1
  • page-state-bridge.fetchMediaList (cyclomatic 38) app/src/main/assets/webrequests/js/page-state-bridge.js:1470 — page-state-bridge.fetchMediaList has cyclomatic complexity 38 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · vimeo.parseVimeoConfig (cyclomatic 38) · ×1
  • vimeo.parseVimeoConfig (cyclomatic 38) app/src/main/assets/webrequests/js/parsers/vimeo.js:116 — vimeo.parseVimeoConfig has cyclomatic complexity 38 (threshold 15). Of this number, 35 points are the body's own statements and 3 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadItemAdapter.bindFull (cyclomatic 37) · ×1
  • DownloadItemAdapter.bindFull (cyclomatic 37) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:811 — DownloadItemAdapter.bindFull has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · content.census (cyclomatic 37) · ×1
  • content.census (cyclomatic 37) app/src/debug/assets/siteaudit/content.js:142 — content.census has cyclomatic complexity 37 (threshold 15). Most of this is not in the body itself: 7 of the 37 points are its own statements and the rest belongs to one function literal inside it that branches (line 146). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · page-state-bridge.resolveBilibiliMeta (cyclomatic 37) · ×1
  • page-state-bridge.resolveBilibiliMeta (cyclomatic 37) app/src/main/assets/webrequests/js/page-state-bridge.js:233 — page-state-bridge.resolveBilibiliMeta has cyclomatic complexity 37 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · server.server (cyclomatic 37) · ×1
  • server.server (cyclomatic 37) signaling/server.js:146 — server.server has cyclomatic complexity 37 (threshold 15). Of this number, 27 points are the body's own statements and 10 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · (anonymous) (cyclomatic 37) · ×1
  • (anonymous) (cyclomatic 37) signaling/server.js:146 — (anonymous) has cyclomatic complexity 37 (threshold 15). Of this number, 27 points are the body's own statements and 10 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state.handlePageStateHls (cyclomatic 36) · ×1
  • page-state.handlePageStateHls (cyclomatic 36) app/src/main/assets/webrequests/js/parsers/page-state.js:303 — page-state.handlePageStateHls has cyclomatic complexity 36 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · DeezerStrategy.execute (cyclomatic 35) · ×1
  • DeezerStrategy.execute (cyclomatic 35) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:73 — DeezerStrategy.execute has cyclomatic complexity 35 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · FFmpegMuxStrategy.execute (cyclomatic 35) · ×1
  • FFmpegMuxStrategy.execute (cyclomatic 35) app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:61 — FFmpegMuxStrategy.execute has cyclomatic complexity 35 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · VaultBackupWorker.doWork (cyclomatic 35) · ×1
  • VaultBackupWorker.doWork (cyclomatic 35) app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:260 — VaultBackupWorker.doWork has cyclomatic complexity 35 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FFmpegOkhttp.okhttpOpen (cyclomatic 34) · ×1
  • FFmpegOkhttp.okhttpOpen (cyclomatic 34) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:346 — FFmpegOkhttp.okhttpOpen has cyclomatic complexity 34 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · SettingsActivity.onCreate (cyclomatic 34) · ×1
  • SettingsActivity.onCreate (cyclomatic 34) app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:110 — SettingsActivity.onCreate has cyclomatic complexity 34 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · background.fetchWebStream (cyclomatic 33) · ×1
  • background.fetchWebStream (cyclomatic 33) app/src/main/assets/youtube/background.js:1285 — background.fetchWebStream has cyclomatic complexity 33 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · MegaStrategy.execute (cyclomatic 32) · ×1
  • MegaStrategy.execute (cyclomatic 32) app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:66 — MegaStrategy.execute has cyclomatic complexity 32 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · S3Client.classify (cyclomatic 32) · ×1
  • S3Client.classify (cyclomatic 32) REDACTED:835 — S3Client.classify has cyclomatic complexity 32 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · SabrStrategy.executeInternal (cyclomatic 31) · ×1
  • SabrStrategy.executeInternal (cyclomatic 31) app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:125 — SabrStrategy.executeInternal has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · SabrDownloader.processUmpResponse (cyclomatic 31) · ×1
  • SabrDownloader.processUmpResponse (cyclomatic 31) app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:703 — SabrDownloader.processUmpResponse has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ContentUriUtils.getPath (cyclomatic 31) · ×1
  • ContentUriUtils.getPath (cyclomatic 31) app/src/main/java/com/solarized/firedown/utils/ContentUriUtils.java:38 — ContentUriUtils.getPath has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · UpdateDirectDownload.run (cyclomatic 31) · ×1
  • UpdateDirectDownload.run (cyclomatic 31) app/src/main/java/com/solarized/firedown/UpdateDirectDownload.java:99 — UpdateDirectDownload.run has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · VariantProcessor.process (cyclomatic 30) · ×1
  • VariantProcessor.process (cyclomatic 30) app/src/main/java/com/solarized/firedown/geckoview/VariantProcessor.java:98 — VariantProcessor.process has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FFmpegXml.serialize (cyclomatic 29) · ×1
  • FFmpegXml.serialize (cyclomatic 29) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegXml.java:130 — FFmpegXml.serialize has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · GeckoStreamStrategy.execute (cyclomatic 29) · ×1
  • GeckoStreamStrategy.execute (cyclomatic 29) app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:48 — GeckoStreamStrategy.execute has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BaseDownloadFragment.handleOptionSelection (cyclomatic 29) · ×1
  • BaseDownloadFragment.handleOptionSelection (cyclomatic 29) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:485 — BaseDownloadFragment.handleOptionSelection has cyclomatic complexity 29 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.readPlayerItem (cyclomatic 29) · ×1
  • page-state-bridge.readPlayerItem (cyclomatic 29) app/src/main/assets/webrequests/js/page-state-bridge.js:378 — page-state-bridge.readPlayerItem has cyclomatic complexity 29 (threshold 15). Of this number, 17 points are the body's own statements and 12 belong to 2 function items inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · page-state-bridge.stripTitleTemplate (cyclomatic 29) · ×1
  • page-state-bridge.stripTitleTemplate (cyclomatic 29) app/src/main/assets/webrequests/js/page-state-bridge.js:1746 — page-state-bridge.stripTitleTemplate has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · instagram.parseInstagramQuery (cyclomatic 29) · ×1
  • instagram.parseInstagramQuery (cyclomatic 29) app/src/main/assets/webrequests/js/parsers/instagram.js:515 — instagram.parseInstagramQuery has cyclomatic complexity 29 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · BrowserOptionHolderSheetDialogFragment.onViewCreated (cyclomatic 28) · ×1
  • BrowserOptionHolderSheetDialogFragment.onViewCreated (cyclomatic 28) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:260 — BrowserOptionHolderSheetDialogFragment.onViewCreated has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BaseDownloadFragment.handleMenuAction (cyclomatic 28) · ×1
  • BaseDownloadFragment.handleMenuAction (cyclomatic 28) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:770 — BaseDownloadFragment.handleMenuAction has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CloudBackupListFragment.observeTransfers (cyclomatic 28) · ×1
  • CloudBackupListFragment.observeTransfers (cyclomatic 28) app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:543 — CloudBackupListFragment.observeTransfers has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · JsonHelper.parseVariants (cyclomatic 28) · ×1
  • JsonHelper.parseVariants (cyclomatic 28) app/src/main/java/com/solarized/firedown/utils/JsonHelper.java:187 — JsonHelper.parseVariants has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · content-script.scrapeInlineScripts (cyclomatic 28) · ×1
  • content-script.scrapeInlineScripts (cyclomatic 28) app/src/main/assets/webrequests/js/content-script.js:3825 — content-script.scrapeInlineScripts has cyclomatic complexity 28 (threshold 15). Of this number, 17 points are the body's own statements and 11 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · common.resolveTabId (cyclomatic 28) · ×1
  • common.resolveTabId (cyclomatic 28) app/src/main/assets/webrequests/js/parsers/common.js:637 — common.resolveTabId has cyclomatic complexity 28 (threshold 15). Of this number, 27 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · requests.validateAndClassify (cyclomatic 28) · ×1
  • requests.validateAndClassify (cyclomatic 28) app/src/main/assets/webrequests/js/requests.js:520 — requests.validateAndClassify has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · instagram.sendInstagramItem (cyclomatic 28) · ×1
  • instagram.sendInstagramItem (cyclomatic 28) app/src/main/assets/webrequests/js/parsers/instagram.js:320 — instagram.sendInstagramItem has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state.handlePageStateProgressive (cyclomatic 28) · ×1
  • page-state.handlePageStateProgressive (cyclomatic 28) app/src/main/assets/webrequests/js/parsers/page-state.js:190 — page-state.handlePageStateProgressive has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · background.bootstrapTvSession (cyclomatic 28) · ×1
  • background.bootstrapTvSession (cyclomatic 28) app/src/main/assets/youtube/background.js:927 — background.bootstrapTvSession has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · challenge.fdExtractInlineChallenge (cyclomatic 28) · ×1
  • challenge.fdExtractInlineChallenge (cyclomatic 28) app/src/main/assets/youtube/challenge.js:18 — challenge.fdExtractInlineChallenge has cyclomatic complexity 28 (threshold 15). Of this number, 24 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AppLinkResolver.resolve (cyclomatic 27) · ×1
  • AppLinkResolver.resolve (cyclomatic 27) app/src/main/java/com/solarized/firedown/applinks/AppLinkResolver.java:59 — AppLinkResolver.resolve has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · HomeFragment.onViewCreated (cyclomatic 27) · ×1
  • HomeFragment.onViewCreated (cyclomatic 27) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290 — HomeFragment.onViewCreated has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · content.around (cyclomatic 27) · ×1
  • content.around (cyclomatic 27) app/src/debug/assets/siteaudit/content.js:334 — content.around has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 3 of the 27 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 343, 393, 335). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · content-script.literalSpans (cyclomatic 27) · ×1
  • content-script.literalSpans (cyclomatic 27) app/src/main/assets/webrequests/js/content-script.js:3773 — content-script.literalSpans has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.configTitleFor (cyclomatic 27) · ×1
  • page-state-bridge.configTitleFor (cyclomatic 27) app/src/main/assets/webrequests/js/page-state-bridge.js:554 — page-state-bridge.configTitleFor has cyclomatic complexity 27 (threshold 15). Of this number, 23 points are the body's own statements and 4 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · background.browser.webRequest.onBeforeRequest.addListener() (cyclomatic 27) · ×1
  • background.browser.webRequest.onBeforeRequest.addListener() (cyclomatic 27) app/src/main/assets/youtube/background.js:2652 — background.browser.webRequest.onBeforeRequest.addListener() has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 10 of the 27 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 2677, 2664, 2727, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · MediaHeader.decode (cyclomatic 26) · ×1
  • MediaHeader.decode (cyclomatic 26) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:141 — MediaHeader.decode has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · SettingsFragment.onSharedPreferenceChanged (cyclomatic 26) · ×1
  • SettingsFragment.onSharedPreferenceChanged (cyclomatic 26) app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:407 — SettingsFragment.onSharedPreferenceChanged has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · NestedWebView.onTouchEvent (cyclomatic 26) · ×1
  • NestedWebView.onTouchEvent (cyclomatic 26) app/src/main/java/com/solarized/firedown/ui/NestedWebView.java:137 — NestedWebView.onTouchEvent has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · WebUtils.getTitle (cyclomatic 26) · ×1
  • WebUtils.getTitle (cyclomatic 26) app/src/main/java/com/solarized/firedown/utils/WebUtils.java:380 — WebUtils.getTitle has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · SettingsFragment.updateSummaries (cyclomatic 25) · ×1
  • SettingsFragment.updateSummaries (cyclomatic 25) app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:278 — SettingsFragment.updateSummaries has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: SettingsFragment.onPreferenceClick (cyclomatic 26) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · background.emitYouTubeCaptions (cyclomatic 25) · ×1
  • background.emitYouTubeCaptions (cyclomatic 25) app/src/main/assets/youtube/background.js:1847 — background.emitYouTubeCaptions has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · AddonDetailFragment.bind (cyclomatic 24) · ×1
  • AddonDetailFragment.bind (cyclomatic 24) app/src/main/java/com/solarized/firedown/settings/AddonDetailFragment.java:192 — AddonDetailFragment.bind has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · BaseActivity.addonEventText (cyclomatic 24) · ×1
  • BaseActivity.addonEventText (cyclomatic 24) app/src/main/java/com/solarized/firedown/BaseActivity.java:355 — BaseActivity.addonEventText has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · content-script.captionForFrame (cyclomatic 24) · ×1
  • content-script.captionForFrame (cyclomatic 24) app/src/main/assets/webrequests/js/content-script.js:4115 — content-script.captionForFrame has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.domTitleFor (cyclomatic 24) · ×1
  • page-state-bridge.domTitleFor (cyclomatic 24) app/src/main/assets/webrequests/js/page-state-bridge.js:625 — page-state-bridge.domTitleFor has cyclomatic complexity 24 (threshold 15). Of this number, 20 points are the body's own statements and 4 belong to 2 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · requests.browser.webRequest.onHeadersReceived.addListener() (cyclomatic 24) · ×1
  • requests.browser.webRequest.onHeadersReceived.addListener() (cyclomatic 24) app/src/main/assets/webrequests/js/requests.js:1493 — requests.browser.webRequest.onHeadersReceived.addListener() has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to 4 function items inside it that branch (finish, a function literal at line 1532, a function literal at line 1556, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · GeckoStateDataRepository.archiveInactiveTabsLocked (cyclomatic 23) · ×1
  • GeckoStateDataRepository.archiveInactiveTabsLocked (cyclomatic 23) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:1225 — GeckoStateDataRepository.archiveInactiveTabsLocked has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Call.execute (cyclomatic 23) · ×1
  • Call.execute (cyclomatic 23) REDACTED:682 — Call.execute has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · GlideHelper.load (cyclomatic 23) · ×1
  • GlideHelper.load (cyclomatic 23) app/src/main/java/com/solarized/firedown/GlideHelper.java:967 — GlideHelper.load has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · common.sendVariants (cyclomatic 23) · ×1
  • common.sendVariants (cyclomatic 23) app/src/main/assets/webrequests/js/parsers/common.js:191 — common.sendVariants has cyclomatic complexity 23 (threshold 15). Of this number, 21 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · background.loadSolver (cyclomatic 23) · ×1
  • background.loadSolver (cyclomatic 23) app/src/main/assets/youtube/background.js:42 — background.loadSolver has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · AmoCatalog.toEntry (cyclomatic 22) · ×1
  • AmoCatalog.toEntry (cyclomatic 22) app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:161 — AmoCatalog.toEntry has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CaptureRenditions.otherRendition (cyclomatic 22) · ×1
  • CaptureRenditions.otherRendition (cyclomatic 22) app/src/main/java/com/solarized/firedown/data/capture/CaptureRenditions.java:164 — CaptureRenditions.otherRendition has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadBackupMirror.importMirrorDatabase (cyclomatic 22) · ×1
  • DownloadBackupMirror.importMirrorDatabase (cyclomatic 22) app/src/main/java/com/solarized/firedown/data/DownloadBackupMirror.java:541 — DownloadBackupMirror.importMirrorDatabase has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CompressTask.stoppableRun (cyclomatic 22) · ×1
  • CompressTask.stoppableRun (cyclomatic 22) app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java:51 — CompressTask.stoppableRun has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · GifMakerTask.stoppableRun (cyclomatic 22) · ×1
  • GifMakerTask.stoppableRun (cyclomatic 22) app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:41 — GifMakerTask.stoppableRun has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AddonActionsSheetDialogFragment.bindRow (cyclomatic 22) · ×1
  • AddonActionsSheetDialogFragment.bindRow (cyclomatic 22) app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java:182 — AddonActionsSheetDialogFragment.bindRow has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · BrowserFragment.onLoadRequest (cyclomatic 22) · ×1
  • BrowserFragment.onLoadRequest (cyclomatic 22) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:2875 — BrowserFragment.onLoadRequest has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · common.enumerateMasterNative (cyclomatic 22) · ×1
  • common.enumerateMasterNative (cyclomatic 22) app/src/main/assets/webrequests/js/parsers/common.js:498 — common.enumerateMasterNative has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AddonManager.checkForUpdates (cyclomatic 21) · ×1
  • AddonManager.checkForUpdates (cyclomatic 21) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1445 — AddonManager.checkForUpdates has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BrowserDownloadViewModel.snapshot (cyclomatic 21) · ×1
  • BrowserDownloadViewModel.snapshot (cyclomatic 21) app/src/main/java/com/solarized/firedown/data/models/BrowserDownloadViewModel.java:240 — BrowserDownloadViewModel.snapshot has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FFmpegOkhttp.performSeek (cyclomatic 21) · ×1
  • FFmpegOkhttp.performSeek (cyclomatic 21) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:863 — FFmpegOkhttp.performSeek has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BaseDownloadFragment.setupNavigationResultObserver (cyclomatic 21) · ×1
  • BaseDownloadFragment.setupNavigationResultObserver (cyclomatic 21) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:405 — BaseDownloadFragment.setupNavigationResultObserver has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · HomeIncognitoFragment.onViewCreated (cyclomatic 21) · ×1
  • HomeIncognitoFragment.onViewCreated (cyclomatic 21) app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:224 — HomeIncognitoFragment.onViewCreated has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AddonsFragment.renderCatalog (cyclomatic 21) · ×1
  • AddonsFragment.renderCatalog (cyclomatic 21) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:279 — AddonsFragment.renderCatalog has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · S3Check.run (cyclomatic 21) · ×1
  • S3Check.run (cyclomatic 21) app/src/main/java/com/solarized/firedown/sync/S3Check.java:148 — S3Check.run has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · MultistatusHandler.endElement (cyclomatic 21) · ×1
  • MultistatusHandler.endElement (cyclomatic 21) REDACTED:668 — MultistatusHandler.endElement has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadItemAdapter.onBindViewHolder (cyclomatic 21) · ×1
  • DownloadItemAdapter.onBindViewHolder (cyclomatic 21) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:719 — DownloadItemAdapter.onBindViewHolder has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.findPlayerMedia (cyclomatic 21) · ×1
  • page-state-bridge.findPlayerMedia (cyclomatic 21) app/src/main/assets/webrequests/js/page-state-bridge.js:444 — page-state-bridge.findPlayerMedia has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.readPlayerMedia (cyclomatic 21) · ×1
  • page-state-bridge.readPlayerMedia (cyclomatic 21) app/src/main/assets/webrequests/js/page-state-bridge.js:1531 — page-state-bridge.readPlayerMedia has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · apple-podcasts.processApplePodcastEpisode (cyclomatic 21) · ×1
  • apple-podcasts.processApplePodcastEpisode (cyclomatic 21) app/src/main/assets/webrequests/js/parsers/apple-podcasts.js:83 — apple-podcasts.processApplePodcastEpisode has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · instagram.parseInstagramDashManifest (cyclomatic 21) · ×1
  • instagram.parseInstagramDashManifest (cyclomatic 21) app/src/main/assets/webrequests/js/parsers/instagram.js:194 — instagram.parseInstagramDashManifest has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file's highest cyclomatic complexity: instagram.listenerInstagramApiFilter (cyclomatic 22) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · rumble.collectRumbleMp4 (cyclomatic 21) · ×1
  • rumble.collectRumbleMp4 (cyclomatic 21) app/src/main/assets/webrequests/js/parsers/rumble.js:65 — rumble.collectRumbleMp4 has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · rumble.emitRumbleFeedItem (cyclomatic 21) · ×1
  • rumble.emitRumbleFeedItem (cyclomatic 21) app/src/main/assets/webrequests/js/parsers/rumble.js:146 — rumble.emitRumbleFeedItem has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · telegram.emitVideosFromHtml (cyclomatic 21) · ×1
  • telegram.emitVideosFromHtml (cyclomatic 21) app/src/main/assets/webrequests/js/parsers/telegram.js:148 — telegram.emitVideosFromHtml has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · FFmpegOkhttp.okhttpRead (cyclomatic 20) · ×1
  • FFmpegOkhttp.okhttpRead (cyclomatic 20) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:610 — FFmpegOkhttp.okhttpRead has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · TimedTextStrategy.execute (cyclomatic 20) · ×1
  • TimedTextStrategy.execute (cyclomatic 20) app/src/main/java/com/solarized/firedown/manager/TimedTextStrategy.java:45 — TimedTextStrategy.execute has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · P2pShareController.handleEngineEvent (cyclomatic 20) · ×1
  • P2pShareController.handleEngineEvent (cyclomatic 20) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1830 — P2pShareController.handleEngineEvent has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BrowserFragment.setGeckoViewSession (cyclomatic 20) · ×1
  • BrowserFragment.setGeckoViewSession (cyclomatic 20) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3500 — BrowserFragment.setGeckoViewSession has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · DownloadFragment.observeViewModelData (cyclomatic 20) · ×1
  • DownloadFragment.observeViewModelData (cyclomatic 20) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:393 — DownloadFragment.observeViewModelData has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · VaultRestoreWorker.doWork (cyclomatic 20) · ×1
  • VaultRestoreWorker.doWork (cyclomatic 20) app/src/main/java/com/solarized/firedown/sync/VaultRestoreWorker.java:114 — VaultRestoreWorker.doWork has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · FilmstripTrimSlider.onTouchEvent (cyclomatic 20) · ×1
  • FilmstripTrimSlider.onTouchEvent (cyclomatic 20) app/src/main/java/com/solarized/firedown/ui/FilmstripTrimSlider.java:516 — FilmstripTrimSlider.onTouchEvent has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · engine-page.acceptAnswer (cyclomatic 20) · ×1
  • engine-page.acceptAnswer (cyclomatic 20) app/src/main/assets/p2pshare/engine-page.js:748 — engine-page.acceptAnswer has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.collectPlayableMedia (cyclomatic 20) · ×1
  • page-state-bridge.collectPlayableMedia (cyclomatic 20) app/src/main/assets/webrequests/js/page-state-bridge.js:1266 — page-state-bridge.collectPlayableMedia has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (page-state-bridge.collectPlayableMedia::walkNode) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D1 · Cyclomatic Complexity · bluesky.collectBskyVideos · ×1
  • bluesky.collectBskyVideos::visit (cyclomatic 20) app/src/main/assets/webrequests/js/parsers/bluesky.js:131 — bluesky.collectBskyVideos::visit has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · requests.nameCapturedClip (cyclomatic 20) · ×1
  • requests.nameCapturedClip (cyclomatic 20) app/src/main/assets/webrequests/js/requests.js:925 — requests.nameCapturedClip has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · twitter.emitTweetMedia (cyclomatic 20) · ×1
  • twitter.emitTweetMedia (cyclomatic 20) app/src/main/assets/webrequests/js/parsers/twitter.js:348 — twitter.emitTweetMedia has cyclomatic complexity 20 (threshold 15). Of this number, 17 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · instagram.buildInstagramItemVariants (cyclomatic 20) · ×1
  • instagram.buildInstagramItemVariants (cyclomatic 20) app/src/main/assets/webrequests/js/parsers/instagram.js:264 — instagram.buildInstagramItemVariants has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file's highest cyclomatic complexity: instagram.listenerInstagramApiFilter (cyclomatic 22) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · substack.listenerSubstackMedia (cyclomatic 20) · ×1
  • substack.listenerSubstackMedia (cyclomatic 20) app/src/main/assets/webrequests/js/parsers/substack.js:305 — substack.listenerSubstackMedia has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 4 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 309). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · background.getOrCreateSolvers (cyclomatic 20) · ×1
  • background.getOrCreateSolvers (cyclomatic 20) app/src/main/assets/youtube/background.js:374 — background.getOrCreateSolvers has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FaviconStore.looksLikeImage (cyclomatic 19) · ×1
  • FaviconStore.looksLikeImage (cyclomatic 19) REDACTED:231 — FaviconStore.looksLikeImage has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · PromptDelegate.onFileCallbackResult (cyclomatic 19) · ×1
  • PromptDelegate.onFileCallbackResult (cyclomatic 19) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:753 — PromptDelegate.onFileCallbackResult has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: NavigationDelegate.errorToType (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · DecompressTask.stoppableRun (cyclomatic 19) · ×1
  • DecompressTask.stoppableRun (cyclomatic 19) app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:50 — DecompressTask.stoppableRun has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BaseDownloadFragment.handleTaskFinish (cyclomatic 19) · ×1
  • BaseDownloadFragment.handleTaskFinish (cyclomatic 19) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:940 — BaseDownloadFragment.handleTaskFinish has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · TabsFragment.onViewCreated (cyclomatic 19) · ×1
  • TabsFragment.onViewCreated (cyclomatic 19) app/src/main/java/com/solarized/firedown/phone/fragments/TabsFragment.java:209 — TabsFragment.onViewCreated has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AboutFragment.refreshUpdateRow (cyclomatic 19) · ×1
  • AboutFragment.refreshUpdateRow (cyclomatic 19) app/src/main/java/com/solarized/firedown/settings/AboutFragment.java:268 — AboutFragment.refreshUpdateRow has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · UpdateDownloader.progress (cyclomatic 19) · ×1
  • UpdateDownloader.progress (cyclomatic 19) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:666 — UpdateDownloader.progress has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · engine-page.reportTransport (cyclomatic 19) · ×1
  • engine-page.reportTransport (cyclomatic 19) app/src/main/assets/p2pshare/engine-page.js:410 — engine-page.reportTransport has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 2 of the 19 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 422, 412, 415). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · page-state-bridge.findDash (cyclomatic 19) · ×1
  • page-state-bridge.findDash (cyclomatic 19) app/src/main/assets/webrequests/js/page-state-bridge.js:81 — page-state-bridge.findDash has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to one function literal inside it that branches (line 85). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · requests.isManifestSniffCandidate (cyclomatic 19) · ×1
  • requests.isManifestSniffCandidate (cyclomatic 19) app/src/main/assets/webrequests/js/requests.js:1448 — requests.isManifestSniffCandidate has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · twitter.collectTwitterSsrBodies · ×1
  • twitter.collectTwitterSsrBodies::walk (cyclomatic 19) app/src/main/assets/webrequests/js/parsers/twitter.js:774 — twitter.collectTwitterSsrBodies::walk has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · instagram.scanEmbeddedItems (cyclomatic 19) · ×1
  • instagram.scanEmbeddedItems (cyclomatic 19) app/src/main/assets/webrequests/js/parsers/instagram.js:961 — instagram.scanEmbeddedItems has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: instagram.listenerInstagramApiFilter (cyclomatic 22) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · instagram.listenerInstagramPage (cyclomatic 19) · ×1
  • instagram.listenerInstagramPage (cyclomatic 19) app/src/main/assets/webrequests/js/parsers/instagram.js:1171 — instagram.listenerInstagramPage has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 6 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1180, 1218). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest. This is NOT this file's highest cyclomatic complexity: instagram.listenerInstagramApiFilter (cyclomatic 22) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · CaptureSections.build (cyclomatic 18) · ×1
  • CaptureSections.build (cyclomatic 18) app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:106 — CaptureSections.build has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · MediaListenerWorker.doWork (cyclomatic 18) · ×1
  • MediaListenerWorker.doWork (cyclomatic 18) app/src/main/java/com/solarized/firedown/data/workers/MediaListenerWorker.java:56 — MediaListenerWorker.doWork has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · GeckoInspectTask.prepareEntity (cyclomatic 18) · ×1
  • GeckoInspectTask.prepareEntity (cyclomatic 18) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:238 — GeckoInspectTask.prepareEntity has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · PortDelegate.onPortMessage (cyclomatic 18) · ×1
  • PortDelegate.onPortMessage (cyclomatic 18) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:953 — PortDelegate.onPortMessage has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · GeckoToolbar.updateTheme (cyclomatic 18) · ×1
  • GeckoToolbar.updateTheme (cyclomatic 18) app/src/main/java/com/solarized/firedown/geckoview/GeckoToolbar.java:517 — GeckoToolbar.updateTheme has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · PoTokenGenerator.generate (cyclomatic 18) · ×1
  • PoTokenGenerator.generate (cyclomatic 18) app/src/main/java/com/solarized/firedown/geckoview/PoTokenGenerator.java:455 — PoTokenGenerator.generate has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · P2pShareController.deliverAnswer (cyclomatic 18) · ×1
  • P2pShareController.deliverAnswer (cyclomatic 18) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:2390 — P2pShareController.deliverAnswer has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · SecurityStateSheetDialogFragment.onCreateView (cyclomatic 18) · ×1
  • SecurityStateSheetDialogFragment.onCreateView (cyclomatic 18) app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:132 — SecurityStateSheetDialogFragment.onCreateView has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · MediaViewerFragment.readVideoAspectRatioBlocking (cyclomatic 18) · ×1
  • MediaViewerFragment.readVideoAspectRatioBlocking (cyclomatic 18) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:2411 — MediaViewerFragment.readVideoAspectRatioBlocking has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · AddonDetailFragment.onCreatePreferences (cyclomatic 18) · ×1
  • AddonDetailFragment.onCreatePreferences (cyclomatic 18) app/src/main/java/com/solarized/firedown/settings/AddonDetailFragment.java:97 — AddonDetailFragment.onCreatePreferences has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · WebDavCheck.run (cyclomatic 18) · ×1
  • WebDavCheck.run (cyclomatic 18) app/src/main/java/com/solarized/firedown/sync/WebDavCheck.java:157 — WebDavCheck.run has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · UpdatePatch.apply (cyclomatic 18) · ×1
  • UpdatePatch.apply (cyclomatic 18) app/src/main/java/com/solarized/firedown/update/UpdatePatch.java:168 — UpdatePatch.apply has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · GlideHelper.preloadBrowser (cyclomatic 18) · ×1
  • GlideHelper.preloadBrowser (cyclomatic 18) app/src/main/java/com/solarized/firedown/GlideHelper.java:1140 — GlideHelper.preloadBrowser has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.holdsStateMedia (cyclomatic 18) · ×1
  • page-state-bridge.holdsStateMedia (cyclomatic 18) app/src/main/assets/webrequests/js/page-state-bridge.js:1095 — page-state-bridge.holdsStateMedia has cyclomatic complexity 18 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · page-state-bridge.clipMetaFromPath (cyclomatic 18) · ×1
  • page-state-bridge.clipMetaFromPath (cyclomatic 18) app/src/main/assets/webrequests/js/page-state-bridge.js:1148 — page-state-bridge.clipMetaFromPath has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · js-literal.parseJsValue (cyclomatic 18) · ×1
  • js-literal.parseJsValue (cyclomatic 18) app/src/main/assets/webrequests/js/parsers/js-literal.js:16 — js-literal.parseJsValue has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · requests.classifyXhr (cyclomatic 18) · ×1
  • requests.classifyXhr (cyclomatic 18) app/src/main/assets/webrequests/js/requests.js:621 — requests.classifyXhr has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · newsoveraudio.listenerNoaArticle (cyclomatic 18) · ×1
  • newsoveraudio.listenerNoaArticle (cyclomatic 18) app/src/main/assets/webrequests/js/parsers/newsoveraudio.js:47 — newsoveraudio.listenerNoaArticle has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to one function literal inside it that branches (line 48). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · twitch.fetchTwitchLiveStream (cyclomatic 18) · ×1
  • twitch.fetchTwitchLiveStream (cyclomatic 18) app/src/main/assets/webrequests/js/parsers/twitch.js:229 — twitch.fetchTwitchLiveStream has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · background.getOrCreateCipherOps (cyclomatic 18) · ×1
  • background.getOrCreateCipherOps (cyclomatic 18) app/src/main/assets/youtube/background.js:544 — background.getOrCreateCipherOps has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · background.browser.webRequest.onBeforeRequest.addListener() (cyclomatic 18) · ×1
  • background.browser.webRequest.onBeforeRequest.addListener() (cyclomatic 18) app/src/main/assets/youtube/background.js:2822 — background.browser.webRequest.onBeforeRequest.addListener() has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · 4.afterTextChanged (cyclomatic 17) · ×1
  • 4.afterTextChanged (cyclomatic 17) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:895 — 4.afterTextChanged has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · GeckoInspectTask.processMegaFolder (cyclomatic 17) · ×1
  • GeckoInspectTask.processMegaFolder (cyclomatic 17) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:594 — GeckoInspectTask.processMegaFolder has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · P2pShareService.buildNotification (cyclomatic 17) · ×1
  • P2pShareService.buildNotification (cyclomatic 17) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareService.java:233 — P2pShareService.buildNotification has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · AddonPromptSheetDialogFragment.bind (cyclomatic 17) · ×1
  • AddonPromptSheetDialogFragment.bind (cyclomatic 17) app/src/main/java/com/solarized/firedown/phone/dialogs/AddonPromptSheetDialogFragment.java:86 — AddonPromptSheetDialogFragment.bind has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · BrowserOptionFragment.submitListPreservingScroll (cyclomatic 17) · ×1
  • BrowserOptionFragment.submitListPreservingScroll (cyclomatic 17) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionFragment.java:414 — BrowserOptionFragment.submitListPreservingScroll has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · MediaViewerFragment.findSubtitles (cyclomatic 17) · ×1
  • MediaViewerFragment.findSubtitles (cyclomatic 17) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1134 — MediaViewerFragment.findSubtitles has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · P2pSendFragment.onCreateView (cyclomatic 17) · ×1
  • P2pSendFragment.onCreateView (cyclomatic 17) app/src/main/java/com/solarized/firedown/phone/fragments/P2pSendFragment.java:135 — P2pSendFragment.onCreateView has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · S3Check.failure (cyclomatic 17) · ×1
  • S3Check.failure (cyclomatic 17) app/src/main/java/com/solarized/firedown/sync/S3Check.java:286 — S3Check.failure has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · VaultEngine.backupStream (cyclomatic 17) · ×1
  • VaultEngine.backupStream (cyclomatic 17) app/src/main/java/com/solarized/firedown/sync/VaultEngine.java:118 — VaultEngine.backupStream has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadItemAdapter.bindFinishedInner (cyclomatic 17) · ×1
  • DownloadItemAdapter.bindFinishedInner (cyclomatic 17) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1199 — DownloadItemAdapter.bindFinishedInner has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadItemAdapter.getItemViewType (cyclomatic 17) · ×1
  • DownloadItemAdapter.getItemViewType (cyclomatic 17) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:610 — DownloadItemAdapter.getItemViewType has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · content-script.reportSource (cyclomatic 17) · ×1
  • content-script.reportSource (cyclomatic 17) app/src/main/assets/webrequests/js/content-script.js:3456 — content-script.reportSource has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.repToPlain (cyclomatic 17) · ×1
  • page-state-bridge.repToPlain (cyclomatic 17) app/src/main/assets/webrequests/js/page-state-bridge.js:113 — page-state-bridge.repToPlain has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · page-state-bridge.readJwPlayers (cyclomatic 17) · ×1
  • page-state-bridge.readJwPlayers (cyclomatic 17) app/src/main/assets/webrequests/js/page-state-bridge.js:746 — page-state-bridge.readJwPlayers has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · page-state-bridge.extractMega (cyclomatic 17) · ×1
  • page-state-bridge.extractMega (cyclomatic 17) app/src/main/assets/webrequests/js/page-state-bridge.js:1833 — page-state-bridge.extractMega has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · dailymotion.processDailymotionData (cyclomatic 17) · ×1
  • dailymotion.processDailymotionData (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/dailymotion.js:150 — dailymotion.processDailymotionData has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · js-literal.skipJsExpression (cyclomatic 17) · ×1
  • js-literal.skipJsExpression (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/js-literal.js:54 — js-literal.skipJsExpression has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · requests.responseTotalBytes (cyclomatic 17) · ×1
  • requests.responseTotalBytes (cyclomatic 17) app/src/main/assets/webrequests/js/requests.js:413 — requests.responseTotalBytes has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · requests.handleSnapshotFetch (cyclomatic 17) · ×1
  • requests.handleSnapshotFetch (cyclomatic 17) app/src/main/assets/webrequests/js/requests.js:2460 — requests.handleSnapshotFetch has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: requests.pickCaptureMeta (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · tiktok.tiktokPlayerItems (cyclomatic 17) · ×1
  • tiktok.tiktokPlayerItems (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/tiktok.js:247 — tiktok.tiktokPlayerItems has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · tiktok.handleTikTokItemList · ×1
  • tiktok.handleTikTokItemList::walk (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/tiktok.js:351 — tiktok.handleTikTokItemList::walk has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This shape REPEATS in the file: one other method here (tiktok.handleTikTokItemList) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D1 · Cyclomatic Complexity · twitch.fetchTwitchVod (cyclomatic 17) · ×1
  • twitch.fetchTwitchVod (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/twitch.js:338 — twitch.fetchTwitchVod has cyclomatic complexity 17 (threshold 15). Of this number, 12 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · spotify.extractSpotifyEmbedTracks (cyclomatic 17) · ×1
  • spotify.extractSpotifyEmbedTracks (cyclomatic 17) app/src/main/assets/webrequests/js/parsers/spotify.js:102 — spotify.extractSpotifyEmbedTracks has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · background.resolveTabId (cyclomatic 17) · ×1
  • background.resolveTabId (cyclomatic 17) app/src/main/assets/youtube/background.js:2894 — background.resolveTabId has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · XpiManifest.stripComments (cyclomatic 16) · ×1
  • XpiManifest.stripComments (cyclomatic 16) app/src/main/java/com/solarized/firedown/addons/XpiManifest.java:146 — XpiManifest.stripComments has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FFmpegMetaDataReader.getStreams (cyclomatic 16) · ×1
  • FFmpegMetaDataReader.getStreams (cyclomatic 16) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:486 — FFmpegMetaDataReader.getStreams has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · PromptDelegate.onFilePrompt (cyclomatic 16) · ×1
  • PromptDelegate.onFilePrompt (cyclomatic 16) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:575 — PromptDelegate.onFilePrompt has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: NavigationDelegate.errorToType (cyclomatic 29) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · GeckoInspectTask.fetchMegaThumbnail (cyclomatic 16) · ×1
  • GeckoInspectTask.fetchMegaThumbnail (cyclomatic 16) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:780 — GeckoInspectTask.fetchMegaThumbnail has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · AudioEncodeTask.stoppableRun (cyclomatic 16) · ×1
  • AudioEncodeTask.stoppableRun (cyclomatic 16) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:41 — AudioEncodeTask.stoppableRun has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · DownloadTask.refreshMetadataFromFile (cyclomatic 16) · ×1
  • DownloadTask.refreshMetadataFromFile (cyclomatic 16) app/src/main/java/com/solarized/firedown/manager/DownloadTask.java:577 — DownloadTask.refreshMetadataFromFile has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · P2pHttp.readHead (cyclomatic 16) · ×1
  • P2pHttp.readHead (cyclomatic 16) app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:52 — P2pHttp.readHead has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · P2pShareController.acceptOffer (cyclomatic 16) · ×1
  • P2pShareController.acceptOffer (cyclomatic 16) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1548 — P2pShareController.acceptOffer has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · InfoBottomSheetDialogFragment.onCreateView (cyclomatic 16) · ×1
  • InfoBottomSheetDialogFragment.onCreateView (cyclomatic 16) app/src/main/java/com/solarized/firedown/phone/dialogs/InfoBottomSheetDialogFragment.java:62 — InfoBottomSheetDialogFragment.onCreateView has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · InfoBottomSheetDialogFragment.onItemClick (cyclomatic 16) · ×1
  • InfoBottomSheetDialogFragment.onItemClick (cyclomatic 16) app/src/main/java/com/solarized/firedown/phone/dialogs/InfoBottomSheetDialogFragment.java:136 — InfoBottomSheetDialogFragment.onItemClick has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · DownloadsActivity.handleP2pDeepLink (cyclomatic 16) · ×1
  • DownloadsActivity.handleP2pDeepLink (cyclomatic 16) app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java:194 — DownloadsActivity.handleP2pDeepLink has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · FormatInitMetadata.decode (cyclomatic 16) · ×1
  • FormatInitMetadata.decode (cyclomatic 16) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:237 — FormatInitMetadata.decode has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · BackupLayout.collectEntries (cyclomatic 16) · ×1
  • BackupLayout.collectEntries (cyclomatic 16) app/src/main/java/com/solarized/firedown/sync/BackupLayout.java:188 — BackupLayout.collectEntries has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · JsonHelper.parse (cyclomatic 16) · ×1
  • JsonHelper.parse (cyclomatic 16) app/src/main/java/com/solarized/firedown/utils/JsonHelper.java:26 — JsonHelper.parse has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · UpdateManifest.parse (cyclomatic 16) · ×1
  • UpdateManifest.parse (cyclomatic 16) app/src/main/java/com/solarized/firedown/UpdateManifest.java:107 — UpdateManifest.parse has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · content.consent (cyclomatic 16) · ×1
  • content.consent (cyclomatic 16) app/src/debug/assets/siteaudit/content.js:85 — content.consent has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · engine-page.pumpFile (cyclomatic 16) · ×1
  • engine-page.pumpFile (cyclomatic 16) app/src/main/assets/p2pshare/engine-page.js:831 — engine-page.pumpFile has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: engine-page.bindReceiveChannel (cyclomatic 17) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · content-script.scrapeJsonLdMedia (cyclomatic 16) · ×1
  • content-script.scrapeJsonLdMedia (cyclomatic 16) app/src/main/assets/webrequests/js/content-script.js:3634 — content-script.scrapeJsonLdMedia has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to one function item inside it that branches (visit). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · page-state-bridge.looksLikeRenditionList (cyclomatic 16) · ×1
  • page-state-bridge.looksLikeRenditionList (cyclomatic 16) app/src/main/assets/webrequests/js/page-state-bridge.js:1198 — page-state-bridge.looksLikeRenditionList has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · twitter.extractTwitterSubtitles (cyclomatic 16) · ×1
  • twitter.extractTwitterSubtitles (cyclomatic 16) app/src/main/assets/webrequests/js/parsers/twitter.js:130 — twitter.extractTwitterSubtitles has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · instagram.buildInstagramVariants (cyclomatic 16) · ×1
  • instagram.buildInstagramVariants (cyclomatic 16) app/src/main/assets/webrequests/js/parsers/instagram.js:124 — instagram.buildInstagramVariants has cyclomatic complexity 16 (threshold 15). Of this number, 8 points are the body's own statements and 8 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file's highest cyclomatic complexity: instagram.listenerInstagramApiFilter (cyclomatic 22) is higher and carries no row of its own — it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · videee.collectVideeeVideos · ×1
  • videee.collectVideeeVideos::visit (cyclomatic 16) app/src/main/assets/webrequests/js/parsers/videee.js:93 — videee.collectVideeeVideos::visit has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · substack.entriesOfPost (cyclomatic 16) · ×1
  • substack.entriesOfPost (cyclomatic 16) app/src/main/assets/webrequests/js/parsers/substack.js:148 — substack.entriesOfPost has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · substack.collectSubstackPosts · ×1
  • substack.collectSubstackPosts::walk (cyclomatic 16) app/src/main/assets/webrequests/js/parsers/substack.js:182 — substack.collectSubstackPosts::walk has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · home-slickness-directions.html.render (cyclomatic 16) · ×1
  • home-slickness-directions.html.render (cyclomatic 16) sketches/home-slickness-directions.html:202 — home-slickness-directions.html.render has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 204). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D10 · Test Quality · No assertions · ×1
  • No assertions: crockfordRejectsU app/src/test/java/com/solarized/firedown/sync/crypto/CryptoTest.java:59 — This method's body runs code, and no assertion was recognised in it. Recognised: JUnit's assertion methods (assertEquals, assertTrue, assertInstanceOf, assertThrows, assertThrowsExactly, assertTimeoutPreemptively, assertAll and the rest of JUnit 5's list), assertThat (AssertJ, Hamcrest, Truth), fail, Mockito's verify and the `assert` statement, in the test body and in helper methods of the test's own class or an in-repository base class, followed three calls deep. Verification through a helper on another object or in another class, through a custom matcher library, or through a harness that fails by throwing under some other name is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
D15 · Churn × Complexity Hotspots · Repeated repair · ×1
  • Repeated repair: scripts/device-audit/selftest.mjs scripts/device-audit/selftest.mjs:39 — scripts/device-audit/selftest.mjs changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 6 (its worst body is selftest.tile at line 39), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “Captured: fix the clip names and misses the third device audit found”; “Captured: fix the clip names and duplicates the second device audit found”; “Captured: fix the clip names and duplicates the first device audit found”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-18..2026-11-16, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-18 10:11:26 +00:00' --until='2026-11-16 10:11:26 +00:00' --full-history --no-merges -- scripts/device-audit/selftest.mjs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
D2 · Cognitive Complexity · background.processVideo (cognitive 300) · ×1
  • background.processVideo (cognitive 300) app/src/main/assets/youtube/background.js:1975 — background.processVideo has cognitive complexity 300 (threshold 15). Drivers by points: if/else 57 (163 pts), error handling 14 (50 pts), boolean chains 49, loops 5 (21 pts), ternaries 7 (17 pts) (nesting depth added 168). Of this number, 293 points are the body's own statements and 7 belong to 3 function items inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · BrowserFragment.onViewCreated (cognitive 138) · ×1
  • BrowserFragment.onViewCreated (cognitive 138) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:736 — BrowserFragment.onViewCreated has cognitive complexity 138 (threshold 15). Drivers by points: if/else 94 (127 pts), boolean chains 7, ternaries 2 (3 pts), match/switch 1 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.emitCapture (cognitive 138) · ×1
  • requests.emitCapture (cognitive 138) app/src/main/assets/webrequests/js/requests.js:1027 — requests.emitCapture has cognitive complexity 138 (threshold 15). Drivers by points: if/else 40 (87 pts), boolean chains 34, ternaries 4 (12 pts), error handling 3 (5 pts) (nesting depth added 57). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · instagram.processFilteredInstagramResponse (cognitive 118) · ×1
  • instagram.processFilteredInstagramResponse (cognitive 118) app/src/main/assets/webrequests/js/parsers/instagram.js:797 — instagram.processFilteredInstagramResponse has cognitive complexity 118 (threshold 15). Drivers by points: if/else 18 (73 pts), loops 5 (26 pts), boolean chains 17, ternaries 1 (2 pts) (nesting depth added 77). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · instagram.processInstagramFeedItems (cognitive 83) · ×1
  • instagram.processInstagramFeedItems (cognitive 83) app/src/main/assets/webrequests/js/parsers/instagram.js:1076 — instagram.processInstagramFeedItems has cognitive complexity 83 (threshold 15). Drivers by points: if/else 16 (40 pts), loops 10 (26 pts), boolean chains 17 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · facebook.findNodeStarts (cognitive 81) · ×1
  • facebook.findNodeStarts (cognitive 81) app/src/main/assets/webrequests/js/parsers/facebook.js:119 — facebook.findNodeStarts has cognitive complexity 81 (threshold 15). Drivers by points: if/else 17 (44 pts), boolean chains 21, loops 6 (16 pts) (nesting depth added 37). Of this number, 71 points are the body's own statements and 10 belong to 4 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · (anonymous) (cognitive 80) · ×1
  • (anonymous) (cognitive 80) signaling/server.js:146 — (anonymous) has cognitive complexity 80 (threshold 15). Drivers by points: if/else 30 (72 pts), boolean chains 5, loops 1 (3 pts) (nesting depth added 44). Of this number, 47 points are the body's own statements and 33 belong to 4 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · M3U8Parser.parseMaster (cognitive 78) · ×1
  • M3U8Parser.parseMaster (cognitive 78) app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:97 — M3U8Parser.parseMaster has cognitive complexity 78 (threshold 15). Drivers by points: if/else 26 (51 pts), boolean chains 9, loops 8 (9 pts), ternaries 3 (5 pts), error handling 2 (4 pts) (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.readVideoJs (cognitive 78) · ×1
  • page-state-bridge.readVideoJs (cognitive 78) app/src/main/assets/webrequests/js/page-state-bridge.js:814 — page-state-bridge.readVideoJs has cognitive complexity 78 (threshold 15). Drivers by points: error handling 13 (26 pts), if/else 13 (22 pts), ternaries 6 (16 pts), boolean chains 11, loops 2 (3 pts) (nesting depth added 33). Of this number, 74 points are the body's own statements and 4 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · server.server (cognitive 76) · ×1
  • server.server (cognitive 76) signaling/server.js:146 — server.server has cognitive complexity 76 (threshold 15). Drivers by points: if/else 29 (68 pts), boolean chains 5, loops 1 (3 pts) (nesting depth added 41). Of this number, 47 points are the body's own statements and 29 belong to 4 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · HttpDownloadStrategy.execute (cognitive 70) · ×1
  • HttpDownloadStrategy.execute (cognitive 70) app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java:60 — HttpDownloadStrategy.execute has cognitive complexity 70 (threshold 15). Drivers by points: if/else 28 (44 pts), boolean chains 15, ternaries 3 (5 pts), error handling 2 (3 pts), loops 2 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.browser.runtime.onMessage.addListener() (cognitive 70) · ×1
  • requests.browser.runtime.onMessage.addListener() (cognitive 70) app/src/main/assets/webrequests/js/requests.js:2502 — requests.browser.runtime.onMessage.addListener() has cognitive complexity 70 (threshold 15). Drivers by points: if/else 26 (49 pts), ternaries 4 (9 pts), boolean chains 8, error handling 1 (3 pts), loops 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SabrDownloader.download (cognitive 69) · ×1
  • SabrDownloader.download (cognitive 69) app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:278 — SabrDownloader.download has cognitive complexity 69 (threshold 15). Drivers by points: if/else 23 (45 pts), boolean chains 11, error handling 2 (5 pts), ternaries 2 (5 pts), loops 2 (3 pts) (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content-script.scrapeInlineScripts (cognitive 68) · ×1
  • content-script.scrapeInlineScripts (cognitive 68) app/src/main/assets/webrequests/js/content-script.js:3825 — content-script.scrapeInlineScripts has cognitive complexity 68 (threshold 15). Drivers by points: if/else 13 (38 pts), loops 7 (20 pts), boolean chains 5, error handling 1 (3 pts), ternaries 1 (2 pts) (nesting depth added 41). Of this number, 31 points are the body's own statements and 37 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.buildAdaptiveVariants (cognitive 67) · ×1
  • background.buildAdaptiveVariants (cognitive 67) app/src/main/assets/youtube/background.js:1561 — background.buildAdaptiveVariants has cognitive complexity 67 (threshold 15). Drivers by points: if/else 17 (30 pts), boolean chains 24, ternaries 3 (8 pts), error handling 1 (3 pts), loops 2 (nesting depth added 20). Of this number, 63 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.emitOneGroup (cognitive 66) · ×1
  • page-state-bridge.emitOneGroup (cognitive 66) app/src/main/assets/webrequests/js/page-state-bridge.js:1617 — page-state-bridge.emitOneGroup has cognitive complexity 66 (threshold 15). Drivers by points: if/else 17 (33 pts), loops 9 (17 pts), boolean chains 14, ternaries 2 (nesting depth added 24). Of this number, 61 points are the body's own statements and 5 belong to 3 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FileUriHelper.getFileExtensionFromMimeType (cognitive 65) · ×1
  • FileUriHelper.getFileExtensionFromMimeType (cognitive 65) app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:803 — FileUriHelper.getFileExtensionFromMimeType has cognitive complexity 65 (threshold 15). Drivers by points: if/else 54 (55 pts), boolean chains 10 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · page-state-bridge.readDomMedia (cognitive 64) · ×1
  • page-state-bridge.readDomMedia (cognitive 64) app/src/main/assets/webrequests/js/page-state-bridge.js:664 — page-state-bridge.readDomMedia has cognitive complexity 64 (threshold 15). Drivers by points: error handling 11 (25 pts), if/else 11 (19 pts), boolean chains 12, loops 3 (5 pts), ternaries 2 (3 pts) (nesting depth added 25). Of this number, 51 points are the body's own statements and 13 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ContentUriUtils.getPath (cognitive 63) · ×1
  • ContentUriUtils.getPath (cognitive 63) app/src/main/java/com/solarized/firedown/utils/ContentUriUtils.java:38 — ContentUriUtils.getPath has cognitive complexity 63 (threshold 15). Drivers by points: if/else 28 (49 pts), error handling 2 (8 pts), loops 1 (4 pts), boolean chains 2 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CloudBackupListFragment.observeTransfers (cognitive 62) · ×1
  • CloudBackupListFragment.observeTransfers (cognitive 62) app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:543 — CloudBackupListFragment.observeTransfers has cognitive complexity 62 (threshold 15). Drivers by points: if/else 14 (40 pts), boolean chains 9, ternaries 2 (6 pts), error handling 1 (5 pts), loops 1 (2 pts) (nesting depth added 35). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FileUriHelper.getMimeTypeFromFile (cognitive 58) · ×1
  • FileUriHelper.getMimeTypeFromFile (cognitive 58) app/src/main/java/com/solarized/firedown/utils/FileUriHelper.java:551 — FileUriHelper.getMimeTypeFromFile has cognitive complexity 58 (threshold 15). Drivers by points: if/else 55 (58 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · common.parseHlsMaster (cognitive 58) · ×1
  • common.parseHlsMaster (cognitive 58) app/src/main/assets/webrequests/js/parsers/common.js:282 — common.parseHlsMaster has cognitive complexity 58 (threshold 15). Drivers by points: if/else 15 (31 pts), boolean chains 21, loops 5 (6 pts) (nesting depth added 17). Of this number, 57 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.decideCapture (cognitive 57) · ×1
  • requests.decideCapture (cognitive 57) app/src/main/assets/webrequests/js/requests.js:702 — requests.decideCapture has cognitive complexity 57 (threshold 15). Drivers by points: if/else 27 (43 pts), boolean chains 13, ternaries 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SabrMessages.buildAbrRequest (cognitive 56) · ×1
  • SabrMessages.buildAbrRequest (cognitive 56) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:551 — SabrMessages.buildAbrRequest has cognitive complexity 56 (threshold 15). Drivers by points: if/else 15 (23 pts), ternaries 11 (13 pts), loops 5 (11 pts), boolean chains 9 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tiktok.handleTikTokItemList (cognitive 54) · ×1
  • tiktok.handleTikTokItemList (cognitive 54) app/src/main/assets/webrequests/js/parsers/tiktok.js:305 — tiktok.handleTikTokItemList has cognitive complexity 54 (threshold 15). Drivers by points: if/else 20 (37 pts), boolean chains 24, loops 5 (11 pts), ternaries 3 (6 pts), error handling 1 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (tiktok.handleTikTokItemList::walk) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · FFmpegXml.serialize (cognitive 53) · ×1
  • FFmpegXml.serialize (cognitive 53) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegXml.java:130 — FFmpegXml.serialize has cognitive complexity 53 (threshold 15). Drivers by points: if/else 14 (42 pts), loops 3 (7 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · VaultBackupWorker.doWork (cognitive 53) · ×1
  • VaultBackupWorker.doWork (cognitive 53) app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:260 — VaultBackupWorker.doWork has cognitive complexity 53 (threshold 15). Drivers by points: if/else 22 (36 pts), error handling 7 (9 pts), ternaries 3 (5 pts), boolean chains 3 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.fetchTvHtml5Stream (cognitive 53) · ×1
  • background.fetchTvHtml5Stream (cognitive 53) app/src/main/assets/youtube/background.js:1095 — background.fetchTvHtml5Stream has cognitive complexity 53 (threshold 15). Drivers by points: if/else 14 (21 pts), ternaries 8 (14 pts), boolean chains 12, error handling 3 (6 pts) (nesting depth added 16). Of this number, 52 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MediaHeader.decode (cognitive 51) · ×1
  • MediaHeader.decode (cognitive 51) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:141 — MediaHeader.decode has cognitive complexity 51 (threshold 15). Drivers by points: if/else 24 (48 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · JsonHelper.parseVariants (cognitive 51) · ×1
  • JsonHelper.parseVariants (cognitive 51) app/src/main/java/com/solarized/firedown/utils/JsonHelper.java:187 — JsonHelper.parseVariants has cognitive complexity 51 (threshold 15). Drivers by points: if/else 14 (26 pts), ternaries 5 (14 pts), boolean chains 5, loops 2 (4 pts), error handling 1 (2 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · common.resolveTabId (cognitive 51) · ×1
  • common.resolveTabId (cognitive 51) app/src/main/assets/webrequests/js/parsers/common.js:637 — common.resolveTabId has cognitive complexity 51 (threshold 15). Drivers by points: if/else 18 (32 pts), error handling 3 (7 pts), ternaries 2 (6 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 23). Of this number, 50 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BrowserOptionHolderSheetDialogFragment.onViewCreated (cognitive 49) · ×1
  • BrowserOptionHolderSheetDialogFragment.onViewCreated (cognitive 49) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:260 — BrowserOptionHolderSheetDialogFragment.onViewCreated has cognitive complexity 49 (threshold 15). Drivers by points: if/else 23 (42 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadItemAdapter.bindFull (cognitive 49) · ×1
  • DownloadItemAdapter.bindFull (cognitive 49) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:811 — DownloadItemAdapter.bindFull has cognitive complexity 49 (threshold 15). Drivers by points: if/else 18 (22 pts), ternaries 11 (18 pts), boolean chains 8, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoStateDataRepository.archiveInactiveTabsLocked (cognitive 47) · ×1
  • GeckoStateDataRepository.archiveInactiveTabsLocked (cognitive 47) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:1225 — GeckoStateDataRepository.archiveInactiveTabsLocked has cognitive complexity 47 (threshold 15). Drivers by points: if/else 16 (35 pts), loops 5 (9 pts), boolean chains 3 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · VariantProcessor.process (cognitive 47) · ×1
  • VariantProcessor.process (cognitive 47) app/src/main/java/com/solarized/firedown/geckoview/VariantProcessor.java:98 — VariantProcessor.process has cognitive complexity 47 (threshold 15). Drivers by points: if/else 17 (29 pts), boolean chains 7, loops 3 (6 pts), ternaries 3 (4 pts), error handling 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FFmpegMetaDataReader.getStreams (cognitive 46) · ×1
  • FFmpegMetaDataReader.getStreams (cognitive 46) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:486 — FFmpegMetaDataReader.getStreams has cognitive complexity 46 (threshold 15). Drivers by points: if/else 12 (35 pts), loops 2 (5 pts), ternaries 1 (4 pts), boolean chains 2 (nesting depth added 29). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · FFmpegOkhttp.okhttpOpen (cognitive 42) · ×1
  • FFmpegOkhttp.okhttpOpen (cognitive 42) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:346 — FFmpegOkhttp.okhttpOpen has cognitive complexity 42 (threshold 15). Drivers by points: if/else 22 (28 pts), boolean chains 8, loops 2 (4 pts), error handling 2 (nesting depth added 8). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · SabrStrategy.executeInternal (cognitive 42) · ×1
  • SabrStrategy.executeInternal (cognitive 42) app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:125 — SabrStrategy.executeInternal has cognitive complexity 42 (threshold 15). Drivers by points: if/else 22 (32 pts), ternaries 4 (5 pts), boolean chains 4, error handling 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BaseDownloadFragment.handleMenuAction (cognitive 42) · ×1
  • BaseDownloadFragment.handleMenuAction (cognitive 42) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:770 — BaseDownloadFragment.handleMenuAction has cognitive complexity 42 (threshold 15). Drivers by points: if/else 22 (30 pts), ternaries 3 (7 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GlideHelper.load (cognitive 42) · ×1
  • GlideHelper.load (cognitive 42) app/src/main/java/com/solarized/firedown/GlideHelper.java:967 — GlideHelper.load has cognitive complexity 42 (threshold 15). Drivers by points: if/else 18 (32 pts), boolean chains 8, ternaries 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.stripTitleTemplate (cognitive 42) · ×1
  • page-state-bridge.stripTitleTemplate (cognitive 42) app/src/main/assets/webrequests/js/page-state-bridge.js:1746 — page-state-bridge.stripTitleTemplate has cognitive complexity 42 (threshold 15). Drivers by points: if/else 10 (20 pts), loops 8 (12 pts), boolean chains 8, ternaries 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FFmpegMetaDataReader.getMimeType (cognitive 41) · ×1
  • FFmpegMetaDataReader.getMimeType (cognitive 41) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:389 — FFmpegMetaDataReader.getMimeType has cognitive complexity 41 (threshold 15). Drivers by points: if/else 30 (38 pts), match/switch 1 (3 pts) (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · NestedWebView.onTouchEvent (cognitive 41) · ×1
  • NestedWebView.onTouchEvent (cognitive 41) app/src/main/java/com/solarized/firedown/ui/NestedWebView.java:137 — NestedWebView.onTouchEvent has cognitive complexity 41 (threshold 15). Drivers by points: if/else 18 (38 pts), boolean chains 2, match/switch 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DeezerStrategy.execute (cognitive 40) · ×1
  • DeezerStrategy.execute (cognitive 40) app/src/main/java/com/solarized/firedown/manager/DeezerStrategy.java:73 — DeezerStrategy.execute has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (21 pts), boolean chains 6, ternaries 5 (6 pts), error handling 4 (5 pts), loops 2 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · FFmpegMuxStrategy.execute (cognitive 40) · ×1
  • FFmpegMuxStrategy.execute (cognitive 40) app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:61 — FFmpegMuxStrategy.execute has cognitive complexity 40 (threshold 15). Drivers by points: if/else 25 (30 pts), boolean chains 5, error handling 3, ternaries 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · UpdateDirectDownload.run (cognitive 40) · ×1
  • UpdateDirectDownload.run (cognitive 40) app/src/main/java/com/solarized/firedown/UpdateDirectDownload.java:99 — UpdateDirectDownload.run has cognitive complexity 40 (threshold 15). Drivers by points: if/else 18 (26 pts), boolean chains 6, ternaries 5 (6 pts), error handling 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.bootstrapTvSession (cognitive 39) · ×1
  • background.bootstrapTvSession (cognitive 39) app/src/main/assets/youtube/background.js:927 — background.bootstrapTvSession has cognitive complexity 39 (threshold 15). Drivers by points: if/else 20 (30 pts), boolean chains 5, error handling 3 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoStreamStrategy.execute (cognitive 38) · ×1
  • GeckoStreamStrategy.execute (cognitive 38) app/src/main/java/com/solarized/firedown/manager/GeckoStreamStrategy.java:48 — GeckoStreamStrategy.execute has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (15 pts), ternaries 7 (14 pts), boolean chains 5, error handling 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state.handlePageStateHls (cognitive 38) · ×1
  • page-state.handlePageStateHls (cognitive 38) app/src/main/assets/webrequests/js/parsers/page-state.js:303 — page-state.handlePageStateHls has cognitive complexity 38 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 12, error handling 3, ternaries 3 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · background.loadSolver (cognitive 38) · ×1
  • background.loadSolver (cognitive 38) app/src/main/assets/youtube/background.js:42 — background.loadSolver has cognitive complexity 38 (threshold 15). Drivers by points: if/else 8 (14 pts), ternaries 2 (9 pts), error handling 4 (8 pts), boolean chains 7 (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · DownloadBackupMirror.importMirrorDatabase (cognitive 37) · ×1
  • DownloadBackupMirror.importMirrorDatabase (cognitive 37) app/src/main/java/com/solarized/firedown/data/DownloadBackupMirror.java:541 — DownloadBackupMirror.importMirrorDatabase has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (25 pts), error handling 3 (5 pts), loops 4 (5 pts), boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BaseDownloadFragment.handleOptionSelection (cognitive 37) · ×1
  • BaseDownloadFragment.handleOptionSelection (cognitive 37) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:485 — BaseDownloadFragment.handleOptionSelection has cognitive complexity 37 (threshold 15). Drivers by points: if/else 27 (35 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · Call.execute (cognitive 37) · ×1
  • Call.execute (cognitive 37) REDACTED:682 — Call.execute has cognitive complexity 37 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 9, ternaries 3 (7 pts), error handling 1 (2 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadItemAdapter.onBindViewHolder (cognitive 37) · ×1
  • DownloadItemAdapter.onBindViewHolder (cognitive 37) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:719 — DownloadItemAdapter.onBindViewHolder has cognitive complexity 37 (threshold 15). Drivers by points: ternaries 9 (23 pts), if/else 6 (9 pts), boolean chains 5 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.validateAndClassify (cognitive 37) · ×1
  • requests.validateAndClassify (cognitive 37) app/src/main/assets/webrequests/js/requests.js:520 — requests.validateAndClassify has cognitive complexity 37 (threshold 15). Drivers by points: if/else 18 (29 pts), boolean chains 8 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · vimeo.parseVimeoConfig (cognitive 37) · ×1
  • vimeo.parseVimeoConfig (cognitive 37) app/src/main/assets/webrequests/js/parsers/vimeo.js:116 — vimeo.parseVimeoConfig has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 13, loops 3, ternaries 2 (3 pts) (nesting depth added 6). Of this number, 34 points are the body's own statements and 3 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MegaStrategy.execute (cognitive 36) · ×1
  • MegaStrategy.execute (cognitive 36) app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:66 — MegaStrategy.execute has cognitive complexity 36 (threshold 15). Drivers by points: if/else 16 (21 pts), boolean chains 6, ternaries 4, error handling 3, loops 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · BaseDownloadFragment.setupNavigationResultObserver (cognitive 36) · ×1
  • BaseDownloadFragment.setupNavigationResultObserver (cognitive 36) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:405 — BaseDownloadFragment.setupNavigationResultObserver has cognitive complexity 36 (threshold 15). Drivers by points: if/else 17 (33 pts), boolean chains 3 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content.around (cognitive 36) · ×1
  • content.around (cognitive 36) app/src/debug/assets/siteaudit/content.js:334 — content.around has cognitive complexity 36 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 8, loops 3 (6 pts), ternaries 2 (nesting depth added 12). Most of this is not in the body itself: 2 of the 36 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 343, 393, 335). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · page-state-bridge.resolveBilibiliMeta (cognitive 36) · ×1
  • page-state-bridge.resolveBilibiliMeta (cognitive 36) app/src/main/assets/webrequests/js/page-state-bridge.js:233 — page-state-bridge.resolveBilibiliMeta has cognitive complexity 36 (threshold 15). Drivers by points: boolean chains 13, error handling 8 (13 pts), if/else 5 (7 pts), loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.configTitleFor (cognitive 36) · ×1
  • page-state-bridge.configTitleFor (cognitive 36) app/src/main/assets/webrequests/js/page-state-bridge.js:554 — page-state-bridge.configTitleFor has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (17 pts), boolean chains 9, loops 3 (5 pts), error handling 2 (3 pts), ternaries 2 (nesting depth added 12). Of this number, 32 points are the body's own statements and 4 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · instagram.sendInstagramItem (cognitive 36) · ×1
  • instagram.sendInstagramItem (cognitive 36) app/src/main/assets/webrequests/js/parsers/instagram.js:320 — instagram.sendInstagramItem has cognitive complexity 36 (threshold 15). Drivers by points: ternaries 5 (15 pts), boolean chains 13, if/else 4 (6 pts), loops 1 (2 pts) (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · background.fetchWebStream (cognitive 36) · ×1
  • background.fetchWebStream (cognitive 36) app/src/main/assets/youtube/background.js:1285 — background.fetchWebStream has cognitive complexity 36 (threshold 15). Drivers by points: boolean chains 17, if/else 8 (9 pts), ternaries 5 (6 pts), error handling 2 (3 pts), loops 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · content-script.literalSpans (cognitive 35) · ×1
  • content-script.literalSpans (cognitive 35) app/src/main/assets/webrequests/js/content-script.js:3773 — content-script.literalSpans has cognitive complexity 35 (threshold 15). Drivers by points: if/else 9 (20 pts), boolean chains 8, ternaries 2 (6 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.collectPlayableMedia (cognitive 35) · ×1
  • page-state-bridge.collectPlayableMedia (cognitive 35) app/src/main/assets/webrequests/js/page-state-bridge.js:1266 — page-state-bridge.collectPlayableMedia has cognitive complexity 35 (threshold 15). Drivers by points: if/else 48 (98 pts), error handling 11 (25 pts), boolean chains 23, loops 13 (23 pts), ternaries 1 (2 pts) (nesting depth added 75). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: 2 other methods here (page-state-bridge.collectPlayableMedia::fillMeta, page-state-bridge.collectPlayableMedia::walkNode) have the same decision points, in the same order, at the same nesting depths — so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · instagram.parseInstagramQuery (cognitive 35) · ×1
  • instagram.parseInstagramQuery (cognitive 35) app/src/main/assets/webrequests/js/parsers/instagram.js:515 — instagram.parseInstagramQuery has cognitive complexity 35 (threshold 15). Drivers by points: boolean chains 18, if/else 6 (12 pts), loops 2 (5 pts) (nesting depth added 9). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · FFmpegOkhttp.okhttpRead (cognitive 34) · ×1
  • FFmpegOkhttp.okhttpRead (cognitive 34) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:610 — FFmpegOkhttp.okhttpRead has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (25 pts), boolean chains 4, loops 2 (3 pts), error handling 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SabrDownloader.processUmpResponse (cognitive 34) · ×1
  • SabrDownloader.processUmpResponse (cognitive 34) app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:703 — SabrDownloader.processUmpResponse has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 3 (6 pts), boolean chains 5, ternaries 1 (2 pts), error handling 1, match/switch 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadItemAdapter.bindProgressInner (cognitive 34) · ×1
  • DownloadItemAdapter.bindProgressInner (cognitive 34) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1095 — DownloadItemAdapter.bindProgressInner has cognitive complexity 34 (threshold 15). Drivers by points: if/else 12 (25 pts), ternaries 2 (7 pts), boolean chains 2 (nesting depth added 18). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · background.getOrCreateSolvers (cognitive 34) · ×1
  • background.getOrCreateSolvers (cognitive 34) app/src/main/assets/youtube/background.js:374 — background.getOrCreateSolvers has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (17 pts), error handling 4 (10 pts), ternaries 2 (4 pts), boolean chains 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CaptureSections.build (cognitive 33) · ×1
  • CaptureSections.build (cognitive 33) app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:106 — CaptureSections.build has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (21 pts), ternaries 2 (6 pts), boolean chains 4, loops 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SettingsActivity.onCreate (cognitive 33) · ×1
  • SettingsActivity.onCreate (cognitive 33) app/src/main/java/com/solarized/firedown/phone/SettingsActivity.java:110 — SettingsActivity.onCreate has cognitive complexity 33 (threshold 15). Drivers by points: if/else 30, boolean chains 3. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · CompressTask.stoppableRun (cognitive 32) · ×1
  • CompressTask.stoppableRun (cognitive 32) app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java:51 — CompressTask.stoppableRun has cognitive complexity 32 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 4, loops 3 (4 pts), ternaries 2 (3 pts), error handling 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FormatInitMetadata.decode (cognitive 31) · ×1
  • FormatInitMetadata.decode (cognitive 31) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:237 — FormatInitMetadata.decode has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (28 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SettingsFragment.updateSummaries (cognitive 31) · ×1
  • SettingsFragment.updateSummaries (cognitive 31) app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:278 — SettingsFragment.updateSummaries has cognitive complexity 31 (threshold 15). Drivers by points: if/else 18 (23 pts), match/switch 1 (4 pts), ternaries 2 (4 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadItemAdapter.bindFinishedInner (cognitive 31) · ×1
  • DownloadItemAdapter.bindFinishedInner (cognitive 31) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1199 — DownloadItemAdapter.bindFinishedInner has cognitive complexity 31 (threshold 15). Drivers by points: ternaries 4 (14 pts), if/else 9 (13 pts), boolean chains 4 (nesting depth added 14). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · page-state-bridge.findPlayerMedia (cognitive 31) · ×1
  • page-state-bridge.findPlayerMedia (cognitive 31) app/src/main/assets/webrequests/js/page-state-bridge.js:444 — page-state-bridge.findPlayerMedia has cognitive complexity 31 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 6 (11 pts), boolean chains 3, error handling 1 (2 pts), ternaries 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.readPlayerMedia (cognitive 31) · ×1
  • page-state-bridge.readPlayerMedia (cognitive 31) app/src/main/assets/webrequests/js/page-state-bridge.js:1531 — page-state-bridge.readPlayerMedia has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (16 pts), error handling 4 (6 pts), loops 4 (5 pts), boolean chains 3, ternaries 1 (nesting depth added 11). Of this number, 30 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AppLinkResolver.resolve (cognitive 30) · ×1
  • AppLinkResolver.resolve (cognitive 30) app/src/main/java/com/solarized/firedown/applinks/AppLinkResolver.java:59 — AppLinkResolver.resolve has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (14 pts), boolean chains 8, ternaries 6 (8 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · BrowserDownloadViewModel.snapshot (cognitive 30) · ×1
  • BrowserDownloadViewModel.snapshot (cognitive 30) app/src/main/java/com/solarized/firedown/data/models/BrowserDownloadViewModel.java:240 — BrowserDownloadViewModel.snapshot has cognitive complexity 30 (threshold 15). Drivers by points: if/else 7 (13 pts), ternaries 6 (9 pts), boolean chains 6, loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · HomeFragment.onViewCreated (cognitive 30) · ×1
  • HomeFragment.onViewCreated (cognitive 30) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290 — HomeFragment.onViewCreated has cognitive complexity 30 (threshold 15). Drivers by points: if/else 23 (24 pts), boolean chains 3, ternaries 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · FilmstripTrimSlider.onTouchEvent (cognitive 30) · ×1
  • FilmstripTrimSlider.onTouchEvent (cognitive 30) app/src/main/java/com/solarized/firedown/ui/FilmstripTrimSlider.java:516 — FilmstripTrimSlider.onTouchEvent has cognitive complexity 30 (threshold 15). Drivers by points: if/else 16 (28 pts), boolean chains 1, match/switch 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AmoCatalog.toEntry (cognitive 29) · ×1
  • AmoCatalog.toEntry (cognitive 29) app/src/main/java/com/solarized/firedown/addons/AmoCatalog.java:161 — AmoCatalog.toEntry has cognitive complexity 29 (threshold 15). Drivers by points: if/else 17 (23 pts), loops 2 (4 pts), boolean chains 1, ternaries 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FFmpegOkhttp.performSeek (cognitive 29) · ×1
  • FFmpegOkhttp.performSeek (cognitive 29) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:863 — FFmpegOkhttp.performSeek has cognitive complexity 29 (threshold 15). Drivers by points: if/else 17 (25 pts), boolean chains 3, ternaries 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PoTokenGenerator.generate (cognitive 29) · ×1
  • PoTokenGenerator.generate (cognitive 29) app/src/main/java/com/solarized/firedown/geckoview/PoTokenGenerator.java:455 — PoTokenGenerator.generate has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 3, ternaries 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonActionsSheetDialogFragment.bindRow (cognitive 29) · ×1
  • AddonActionsSheetDialogFragment.bindRow (cognitive 29) app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java:182 — AddonActionsSheetDialogFragment.bindRow has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (17 pts), ternaries 5 (8 pts), boolean chains 4 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · BrowserFragment.setGeckoViewSession (cognitive 29) · ×1
  • BrowserFragment.setGeckoViewSession (cognitive 29) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3500 — BrowserFragment.setGeckoViewSession has cognitive complexity 29 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 6 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · MediaViewerFragment.readVideoAspectRatioBlocking (cognitive 29) · ×1
  • MediaViewerFragment.readVideoAspectRatioBlocking (cognitive 29) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:2411 — MediaViewerFragment.readVideoAspectRatioBlocking has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (17 pts), error handling 4 (8 pts), boolean chains 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SabrContextSendingPolicy.decode (cognitive 29) · ×1
  • SabrContextSendingPolicy.decode (cognitive 29) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:470 — SabrContextSendingPolicy.decode has cognitive complexity 29 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 3 (12 pts), loops 2 (5 pts) (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · WebUtils.getTitle (cognitive 29) · ×1
  • WebUtils.getTitle (cognitive 29) app/src/main/java/com/solarized/firedown/utils/WebUtils.java:380 — WebUtils.getTitle has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 7, loops 2, match/switch 1 (2 pts), error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content.census (cognitive 29) · ×1
  • content.census (cognitive 29) app/src/debug/assets/siteaudit/content.js:142 — content.census has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 17, if/else 6 (7 pts), ternaries 4 (5 pts) (nesting depth added 2). Most of this is not in the body itself: 6 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 146). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · background.getOrCreateCipherOps (cognitive 29) · ×1
  • background.getOrCreateCipherOps (cognitive 29) app/src/main/assets/youtube/background.js:544 — background.getOrCreateCipherOps has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (21 pts), error handling 3 (6 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.emitYouTubeCaptions (cognitive 29) · ×1
  • background.emitYouTubeCaptions (cognitive 29) app/src/main/assets/youtube/background.js:1847 — background.emitYouTubeCaptions has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 9, if/else 6 (9 pts), ternaries 3 (7 pts), error handling 2 (3 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · P2pHttp.readHead (cognitive 28) · ×1
  • P2pHttp.readHead (cognitive 28) app/src/main/java/com/solarized/firedown/p2pshare/P2pHttp.java:52 — P2pHttp.readHead has cognitive complexity 28 (threshold 15). Drivers by points: if/else 12 (20 pts), loops 3 (4 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonsFragment.renderCatalog (cognitive 28) · ×1
  • AddonsFragment.renderCatalog (cognitive 28) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:279 — AddonsFragment.renderCatalog has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (15 pts), loops 4 (6 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content-script.captionForFrame (cognitive 28) · ×1
  • content-script.captionForFrame (cognitive 28) app/src/main/assets/webrequests/js/content-script.js:4115 — content-script.captionForFrame has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 8, loops 2 (3 pts), ternaries 2, error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · XpiManifest.stripComments (cognitive 27) · ×1
  • XpiManifest.stripComments (cognitive 27) app/src/main/java/com/solarized/firedown/addons/XpiManifest.java:146 — XpiManifest.stripComments has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 3 (7 pts), boolean chains 6 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MediaListenerWorker.doWork (cognitive 27) · ×1
  • MediaListenerWorker.doWork (cognitive 27) app/src/main/java/com/solarized/firedown/data/workers/MediaListenerWorker.java:56 — MediaListenerWorker.doWork has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 7, error handling 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DecompressTask.stoppableRun (cognitive 27) · ×1
  • DecompressTask.stoppableRun (cognitive 27) app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java:50 — DecompressTask.stoppableRun has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 5, loops 3 (4 pts), ternaries 1 (2 pts), error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · InfoBottomSheetDialogFragment.onCreateView (cognitive 27) · ×1
  • InfoBottomSheetDialogFragment.onCreateView (cognitive 27) app/src/main/java/com/solarized/firedown/phone/dialogs/InfoBottomSheetDialogFragment.java:62 — InfoBottomSheetDialogFragment.onCreateView has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (23 pts), ternaries 2, boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BaseFocusFragment.openItem (cognitive 27) · ×1
  • BaseFocusFragment.openItem (cognitive 27) app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:730 — BaseFocusFragment.openItem has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (23 pts), boolean chains 3, error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SabrDownloader.fetchWithRetry (cognitive 27) · ×1
  • SabrDownloader.fetchWithRetry (cognitive 27) app/src/main/java/com/solarized/firedown/sabr/SabrDownloader.java:597 — SabrDownloader.fetchWithRetry has cognitive complexity 27 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 3 (10 pts), error handling 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonsFragment.applyInstalling (cognitive 27) · ×1
  • AddonsFragment.applyInstalling (cognitive 27) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:361 — AddonsFragment.applyInstalling has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 4 (10 pts), boolean chains 1, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdatePatch.apply (cognitive 27) · ×1
  • UpdatePatch.apply (cognitive 27) app/src/main/java/com/solarized/firedown/update/UpdatePatch.java:168 — UpdatePatch.apply has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 4 (8 pts), boolean chains 3, ternaries 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateDownloader.progress (cognitive 27) · ×1
  • UpdateDownloader.progress (cognitive 27) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:666 — UpdateDownloader.progress has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (14 pts), ternaries 4 (9 pts), boolean chains 3, error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.readPlayerItem (cognitive 27) · ×1
  • page-state-bridge.readPlayerItem (cognitive 27) app/src/main/assets/webrequests/js/page-state-bridge.js:378 — page-state-bridge.readPlayerItem has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 11, if/else 6, error handling 4 (5 pts), ternaries 4, loops 1 (nesting depth added 1). Of this number, 16 points are the body's own statements and 11 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.domTitleFor (cognitive 27) · ×1
  • page-state-bridge.domTitleFor (cognitive 27) app/src/main/assets/webrequests/js/page-state-bridge.js:625 — page-state-bridge.domTitleFor has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (14 pts), error handling 5, boolean chains 4, ternaries 4 (nesting depth added 4). Of this number, 23 points are the body's own statements and 4 belong to 2 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · page-state-bridge.fetchMediaList (cognitive 27) · ×1
  • page-state-bridge.fetchMediaList (cognitive 27) app/src/main/assets/webrequests/js/page-state-bridge.js:1470 — page-state-bridge.fetchMediaList has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 15, if/else 6 (9 pts), error handling 2, loops 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · page-state.handlePageStateProgressive (cognitive 27) · ×1
  • page-state.handlePageStateProgressive (cognitive 27) app/src/main/assets/webrequests/js/parsers/page-state.js:190 — page-state.handlePageStateProgressive has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 11, ternaries 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · AddonManager.checkForUpdates (cognitive 26) · ×1
  • AddonManager.checkForUpdates (cognitive 26) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1445 — AddonManager.checkForUpdates has cognitive complexity 26 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 4, match/switch 1 (2 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadFragment.setupRecyclerView (cognitive 26) · ×1
  • DownloadFragment.setupRecyclerView (cognitive 26) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:262 — DownloadFragment.setupRecyclerView has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 4, ternaries 1 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PlaybackDebugInfo.describe (cognitive 26) · ×1
  • PlaybackDebugInfo.describe (cognitive 26) app/src/main/java/com/solarized/firedown/phone/player/PlaybackDebugInfo.java:52 — PlaybackDebugInfo.describe has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (15 pts), ternaries 3 (7 pts), error handling 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AboutFragment.refreshUpdateRow (cognitive 26) · ×1
  • AboutFragment.refreshUpdateRow (cognitive 26) app/src/main/java/com/solarized/firedown/settings/AboutFragment.java:268 — AboutFragment.refreshUpdateRow has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 4 (8 pts), boolean chains 6 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonDetailFragment.bind (cognitive 26) · ×1
  • AddonDetailFragment.bind (cognitive 26) app/src/main/java/com/solarized/firedown/settings/AddonDetailFragment.java:192 — AddonDetailFragment.bind has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 5, ternaries 3 (4 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · SidecarCache.load (cognitive 26) · ×1
  • SidecarCache.load (cognitive 26) app/src/main/java/com/solarized/firedown/sync/SidecarCache.java:87 — SidecarCache.load has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (6 pts), ternaries 2 (5 pts), error handling 2 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · instagram.parseInstagramDashManifest (cognitive 26) · ×1
  • instagram.parseInstagramDashManifest (cognitive 26) app/src/main/assets/webrequests/js/parsers/instagram.js:194 — instagram.parseInstagramDashManifest has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 13, if/else 5 (10 pts), loops 2 (3 pts) (nesting depth added 6). Of this number, 25 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · instagram.scanEmbeddedItems (cognitive 26) · ×1
  • instagram.scanEmbeddedItems (cognitive 26) app/src/main/assets/webrequests/js/parsers/instagram.js:961 — instagram.scanEmbeddedItems has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4, ternaries 2 (4 pts), error handling 1 (2 pts), loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CaptureRenditions.otherRendition (cognitive 25) · ×1
  • CaptureRenditions.otherRendition (cognitive 25) app/src/main/java/com/solarized/firedown/data/capture/CaptureRenditions.java:164 — CaptureRenditions.otherRendition has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 8, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoStateObserver.writeSessionFile (cognitive 25) · ×1
  • GeckoStateObserver.writeSessionFile (cognitive 25) app/src/main/java/com/solarized/firedown/data/observer/GeckoStateObserver.java:181 — GeckoStateObserver.writeSessionFile has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PromptDelegate.onFileCallbackResult (cognitive 25) · ×1
  • PromptDelegate.onFileCallbackResult (cognitive 25) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:753 — PromptDelegate.onFileCallbackResult has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 7, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SitePermissions.of (cognitive 25) · ×1
  • SitePermissions.of (cognitive 25) app/src/main/java/com/solarized/firedown/geckoview/SitePermissions.java:105 — SitePermissions.of has cognitive complexity 25 (threshold 15). Drivers by points: if/else 4 (10 pts), ternaries 3 (8 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MediaViewerFragment.findSubtitles (cognitive 25) · ×1
  • MediaViewerFragment.findSubtitles (cognitive 25) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:1134 — MediaViewerFragment.findSubtitles has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 3, boolean chains 2, ternaries 1 (2 pts), error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SettingsFragment.onSharedPreferenceChanged (cognitive 25) · ×1
  • SettingsFragment.onSharedPreferenceChanged (cognitive 25) app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:407 — SettingsFragment.onSharedPreferenceChanged has cognitive complexity 25 (threshold 15). Drivers by points: if/else 19 (22 pts), ternaries 1 (3 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · WebDavCheck.run (cognitive 25) · ×1
  • WebDavCheck.run (cognitive 25) app/src/main/java/com/solarized/firedown/sync/WebDavCheck.java:157 — WebDavCheck.run has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 4, error handling 2 (3 pts), ternaries 2 (3 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.holdsStateMedia (cognitive 25) · ×1
  • page-state-bridge.holdsStateMedia (cognitive 25) app/src/main/assets/webrequests/js/page-state-bridge.js:1095 — page-state-bridge.holdsStateMedia has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (10 pts), error handling 3 (7 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · challenge.fdExtractInlineChallenge (cognitive 25) · ×1
  • challenge.fdExtractInlineChallenge (cognitive 25) app/src/main/assets/youtube/challenge.js:18 — challenge.fdExtractInlineChallenge has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 4, error handling 1, loops 1, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PermissionDelegate.onAndroidPermissionsRequest (cognitive 24) · ×1
  • PermissionDelegate.onAndroidPermissionsRequest (cognitive 24) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1673 — PermissionDelegate.onAndroidPermissionsRequest has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GifMakerTask.stoppableRun (cognitive 24) · ×1
  • GifMakerTask.stoppableRun (cognitive 24) app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:41 — GifMakerTask.stoppableRun has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 6 (7 pts), boolean chains 5, error handling 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · Fmp4Muxer.locateTrakDurations (cognitive 24) · ×1
  • Fmp4Muxer.locateTrakDurations (cognitive 24) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:481 — Fmp4Muxer.locateTrakDurations has cognitive complexity 24 (threshold 15). Drivers by points: ternaries 5 (13 pts), if/else 7 (11 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BackupLayout.collectEntries (cognitive 24) · ×1
  • BackupLayout.collectEntries (cognitive 24) app/src/main/java/com/solarized/firedown/sync/BackupLayout.java:188 — BackupLayout.collectEntries has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 5 (6 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · S3Check.run (cognitive 24) · ×1
  • S3Check.run (cognitive 24) app/src/main/java/com/solarized/firedown/sync/S3Check.java:148 — S3Check.run has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 5, loops 1, match/switch 1, ternaries 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MultistatusHandler.endElement (cognitive 24) · ×1
  • MultistatusHandler.endElement (cognitive 24) REDACTED:668 — MultistatusHandler.endElement has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 3, ternaries 1 (2 pts), match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GlideHelper.preloadBrowser (cognitive 24) · ×1
  • GlideHelper.preloadBrowser (cognitive 24) app/src/main/java/com/solarized/firedown/GlideHelper.java:1140 — GlideHelper.preloadBrowser has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 7, ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · instagram.listenerInstagramPage (cognitive 24) · ×1
  • instagram.listenerInstagramPage (cognitive 24) app/src/main/assets/webrequests/js/parsers/instagram.js:1171 — instagram.listenerInstagramPage has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 5, loops 3 (4 pts) (nesting depth added 6). Most of this is not in the body itself: 5 of the 24 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1180, 1218). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · background.protoBytesField (cognitive 24) · ×1
  • background.protoBytesField (cognitive 24) app/src/main/assets/youtube/background.js:2786 — background.protoBytesField has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 2, boolean chains 1 (nesting depth added 10). Of this number, 19 points are the body's own statements and 5 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.resolveTabId (cognitive 24) · ×1
  • background.resolveTabId (cognitive 24) app/src/main/assets/youtube/background.js:2894 — background.resolveTabId has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (12 pts), error handling 3 (6 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 8). Of this number, 23 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadEngine.finishOneDownload (cognitive 23) · ×1
  • DownloadEngine.finishOneDownload (cognitive 23) app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:895 — DownloadEngine.finishOneDownload has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · P2pShareService.buildNotification (cognitive 23) · ×1
  • P2pShareService.buildNotification (cognitive 23) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareService.java:233 — P2pShareService.buildNotification has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 5 (9 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · InfoBottomSheetDialogFragment.onItemClick (cognitive 23) · ×1
  • InfoBottomSheetDialogFragment.onItemClick (cognitive 23) app/src/main/java/com/solarized/firedown/phone/dialogs/InfoBottomSheetDialogFragment.java:136 — InfoBottomSheetDialogFragment.onItemClick has cognitive complexity 23 (threshold 15). Drivers by points: if/else 15 (20 pts), ternaries 1 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BrowserFragment.onItemClick (cognitive 23) · ×1
  • BrowserFragment.onItemClick (cognitive 23) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:3424 — BrowserFragment.onItemClick has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (23 pts) (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · HomeIncognitoFragment.onViewCreated (cognitive 23) · ×1
  • HomeIncognitoFragment.onViewCreated (cognitive 23) app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:224 — HomeIncognitoFragment.onViewCreated has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20 (21 pts), boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · TabsFragment.onViewCreated (cognitive 23) · ×1
  • TabsFragment.onViewCreated (cognitive 23) app/src/main/java/com/solarized/firedown/phone/fragments/TabsFragment.java:209 — TabsFragment.onViewCreated has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 7, ternaries 3 (4 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · DownloadsActivity.handleP2pDeepLink (cognitive 23) · ×1
  • DownloadsActivity.handleP2pDeepLink (cognitive 23) app/src/main/java/com/solarized/firedown/phone/DownloadsActivity.java:194 — DownloadsActivity.handleP2pDeepLink has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (19 pts), boolean chains 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · NextRequestPolicy.decode (cognitive 23) · ×1
  • NextRequestPolicy.decode (cognitive 23) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:305 — NextRequestPolicy.decode has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (20 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (SabrContextUpdate.decode) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · SabrContextUpdate.decode (cognitive 23) · ×1
  • SabrContextUpdate.decode (cognitive 23) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:414 — SabrContextUpdate.decode has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (20 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (NextRequestPolicy.decode) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · S3Client.listUploads (cognitive 23) · ×1
  • S3Client.listUploads (cognitive 23) REDACTED:500 — S3Client.listUploads has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 3, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · WebHistoryAdapter.onBindViewHolder (cognitive 23) · ×1
  • WebHistoryAdapter.onBindViewHolder (cognitive 23) app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:122 — WebHistoryAdapter.onBindViewHolder has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 6 (15 pts), if/else 5 (6 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.looksLikeRenditionList (cognitive 23) · ×1
  • page-state-bridge.looksLikeRenditionList (cognitive 23) app/src/main/assets/webrequests/js/page-state-bridge.js:1198 — page-state-bridge.looksLikeRenditionList has cognitive complexity 23 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 6, loops 2 (3 pts), error handling 1 (2 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · common.enumerateMasterNative (cognitive 23) · ×1
  • common.enumerateMasterNative (cognitive 23) app/src/main/assets/webrequests/js/parsers/common.js:498 — common.enumerateMasterNative has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 6, error handling 1 (2 pts), ternaries 1 (nesting depth added 2). Of this number, 22 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · requests.nativePort.onMessage.addListener() (cognitive 23) · ×1
  • requests.nativePort.onMessage.addListener() (cognitive 23) app/src/main/assets/webrequests/js/requests.js:2247 — requests.nativePort.onMessage.addListener() has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (18 pts), error handling 1 (2 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 11). Of this number, 20 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · twitter.emitTweetMedia (cognitive 23) · ×1
  • twitter.emitTweetMedia (cognitive 23) app/src/main/assets/webrequests/js/parsers/twitter.js:348 — twitter.emitTweetMedia has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 7, if/else 4 (7 pts), ternaries 3 (6 pts), loops 2 (3 pts) (nesting depth added 7). Of this number, 18 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PromptDelegate.onFilePrompt (cognitive 22) · ×1
  • PromptDelegate.onFilePrompt (cognitive 22) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:575 — PromptDelegate.onFilePrompt has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 2 (4 pts), boolean chains 3, loops 1 (2 pts), error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoInspectTask.processMegaFolder (cognitive 22) · ×1
  • GeckoInspectTask.processMegaFolder (cognitive 22) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:594 — GeckoInspectTask.processMegaFolder has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 5, error handling 2 (3 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PortDelegate.onPortMessage (cognitive 22) · ×1
  • PortDelegate.onPortMessage (cognitive 22) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:953 — PortDelegate.onPortMessage has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (12 pts), error handling 3 (4 pts), loops 2 (4 pts), boolean chains 1, ternaries 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · GeckoToolbar.updateTheme (cognitive 22) · ×1
  • GeckoToolbar.updateTheme (cognitive 22) app/src/main/java/com/solarized/firedown/geckoview/GeckoToolbar.java:517 — GeckoToolbar.updateTheme has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (12 pts), ternaries 4 (8 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · TimedTextStrategy.execute (cognitive 22) · ×1
  • TimedTextStrategy.execute (cognitive 22) app/src/main/java/com/solarized/firedown/manager/TimedTextStrategy.java:45 — TimedTextStrategy.execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (13 pts), ternaries 2 (4 pts), boolean chains 2, error handling 2, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · BrowserFragment.onLoadRequest (cognitive 22) · ×1
  • BrowserFragment.onLoadRequest (cognitive 22) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:2875 — BrowserFragment.onLoadRequest has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 8, ternaries 2 (3 pts), match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadFragment.observeViewModelData (cognitive 22) · ×1
  • DownloadFragment.observeViewModelData (cognitive 22) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:393 — DownloadFragment.observeViewModelData has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16 (18 pts), ternaries 3, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · S3Client.getRange (cognitive 22) · ×1
  • S3Client.getRange (cognitive 22) REDACTED:319 — S3Client.getRange has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (17 pts), error handling 2 (4 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · VaultEngine.backupStream (cognitive 22) · ×1
  • VaultEngine.backupStream (cognitive 22) app/src/main/java/com/solarized/firedown/sync/VaultEngine.java:118 — VaultEngine.backupStream has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (8 pts), ternaries 4 (7 pts), boolean chains 4, error handling 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · NavigationUtils.navigateSafe (cognitive 22) · ×1
  • NavigationUtils.navigateSafe (cognitive 22) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:111 — NavigationUtils.navigateSafe has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateApkVerifier.verifySignature (cognitive 22) · ×1
  • UpdateApkVerifier.verifySignature (cognitive 22) app/src/main/java/com/solarized/firedown/UpdateApkVerifier.java:54 — UpdateApkVerifier.verifySignature has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 2 (4 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.readJwPlayers (cognitive 22) · ×1
  • page-state-bridge.readJwPlayers (cognitive 22) app/src/main/assets/webrequests/js/page-state-bridge.js:746 — page-state-bridge.readJwPlayers has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (10 pts), error handling 4 (6 pts), ternaries 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · common.sendVariants (cognitive 22) · ×1
  • common.sendVariants (cognitive 22) app/src/main/assets/webrequests/js/parsers/common.js:191 — common.sendVariants has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12, boolean chains 8, error handling 1 (2 pts) (nesting depth added 1). Of this number, 20 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · dailymotion.processDailymotionData (cognitive 22) · ×1
  • dailymotion.processDailymotionData (cognitive 22) app/src/main/assets/webrequests/js/parsers/dailymotion.js:150 — dailymotion.processDailymotionData has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (14 pts), loops 2 (4 pts), boolean chains 3, ternaries 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · js-literal.skipJsExpression (cognitive 22) · ×1
  • js-literal.skipJsExpression (cognitive 22) app/src/main/assets/webrequests/js/parsers/js-literal.js:54 — js-literal.skipJsExpression has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tiktok.tiktokPlayerItems (cognitive 22) · ×1
  • tiktok.tiktokPlayerItems (cognitive 22) app/src/main/assets/webrequests/js/parsers/tiktok.js:247 — tiktok.tiktokPlayerItems has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 8, ternaries 3 (6 pts), if/else 2 (5 pts), loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · rumble.emitRumbleFeedItem (cognitive 22) · ×1
  • rumble.emitRumbleFeedItem (cognitive 22) app/src/main/assets/webrequests/js/parsers/rumble.js:146 — rumble.emitRumbleFeedItem has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 8, ternaries 2 (4 pts), loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoUblockHelper.onBlockedTotals (cognitive 21) · ×1
  • GeckoUblockHelper.onBlockedTotals (cognitive 21) app/src/main/java/com/solarized/firedown/geckoview/GeckoUblockHelper.java:166 — GeckoUblockHelper.onBlockedTotals has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadRunnable.run (cognitive 21) · ×1
  • DownloadRunnable.run (cognitive 21) app/src/main/java/com/solarized/firedown/manager/DownloadRunnable.java:41 — DownloadRunnable.run has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 2, error handling 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · P2pShareController.deliverAnswer (cognitive 21) · ×1
  • P2pShareController.deliverAnswer (cognitive 21) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:2390 — P2pShareController.deliverAnswer has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · P2pShareController.handleEngineEvent (cognitive 21) · ×1
  • P2pShareController.handleEngineEvent (cognitive 21) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1830 — P2pShareController.handleEngineEvent has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (19 pts), boolean chains 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PopupBrowserSheetDialogFragment.bindQuickRow (cognitive 21) · ×1
  • PopupBrowserSheetDialogFragment.bindQuickRow (cognitive 21) app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:393 — PopupBrowserSheetDialogFragment.bindQuickRow has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 2 (4 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · VaultRestoreWorker.doWork (cognitive 21) · ×1
  • VaultRestoreWorker.doWork (cognitive 21) app/src/main/java/com/solarized/firedown/sync/VaultRestoreWorker.java:114 — VaultRestoreWorker.doWork has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 5, error handling 4, ternaries 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · TabArchiveAdapter.onBindViewHolder (cognitive 21) · ×1
  • TabArchiveAdapter.onBindViewHolder (cognitive 21) app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:96 — TabArchiveAdapter.onBindViewHolder has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 7 (15 pts), boolean chains 3, if/else 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Utils.bundleToString (cognitive 21) · ×1
  • Utils.bundleToString (cognitive 21) app/src/main/java/com/solarized/firedown/utils/Utils.java:421 — Utils.bundleToString has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15 (19 pts), loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · Utils.mapToString (cognitive 21) · ×1
  • Utils.mapToString (cognitive 21) app/src/main/java/com/solarized/firedown/utils/Utils.java:471 — Utils.mapToString has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (9 pts), ternaries 2 (6 pts), error handling 1 (3 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateInstaller.install (cognitive 21) · ×1
  • UpdateInstaller.install (cognitive 21) app/src/main/java/com/solarized/firedown/UpdateInstaller.java:76 — UpdateInstaller.install has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), error handling 2 (4 pts), boolean chains 2, loops 1, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateManifest.parse (cognitive 21) · ×1
  • UpdateManifest.parse (cognitive 21) app/src/main/java/com/solarized/firedown/UpdateManifest.java:107 — UpdateManifest.parse has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 5, loops 2 (4 pts), error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content.dataAttrs (cognitive 21) · ×1
  • content.dataAttrs (cognitive 21) app/src/debug/assets/siteaudit/content.js:278 — content.dataAttrs has cognitive complexity 21 (threshold 15). Drivers by points: if/else 3 (9 pts), ternaries 2 (6 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.clipMetaFromPath (cognitive 21) · ×1
  • page-state-bridge.clipMetaFromPath (cognitive 21) app/src/main/assets/webrequests/js/page-state-bridge.js:1148 — page-state-bridge.clipMetaFromPath has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 6, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AppLinkPolicy.decide (cognitive 20) · ×1
  • AppLinkPolicy.decide (cognitive 20) app/src/main/java/com/solarized/firedown/applinks/AppLinkPolicy.java:98 — AppLinkPolicy.decide has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 2 (6 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CaptureSections.marksByUid (cognitive 20) · ×1
  • CaptureSections.marksByUid (cognitive 20) app/src/main/java/com/solarized/firedown/data/capture/CaptureSections.java:408 — CaptureSections.marksByUid has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (4 pts), ternaries 1 (4 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadTask.refreshMetadataFromFile (cognitive 20) · ×1
  • DownloadTask.refreshMetadataFromFile (cognitive 20) app/src/main/java/com/solarized/firedown/manager/DownloadTask.java:577 — DownloadTask.refreshMetadataFromFile has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 5, error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · TabsHolderFragment.handleBack (cognitive 20) · ×1
  • TabsHolderFragment.handleBack (cognitive 20) app/src/main/java/com/solarized/firedown/phone/fragments/TabsHolderFragment.java:573 — TabsHolderFragment.handleBack has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · JsonToSrtConverter.convert (cognitive 20) · ×1
  • JsonToSrtConverter.convert (cognitive 20) app/src/main/java/com/solarized/firedown/utils/JsonToSrtConverter.java:14 — JsonToSrtConverter.convert has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (14 pts), loops 2 (4 pts), boolean chains 1, error handling 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BaseActivity.addonEventText (cognitive 20) · ×1
  • BaseActivity.addonEventText (cognitive 20) app/src/main/java/com/solarized/firedown/BaseActivity.java:355 — BaseActivity.addonEventText has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 9 (18 pts), boolean chains 1, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · content.consent (cognitive 20) · ×1
  • content.consent (cognitive 20) app/src/debug/assets/siteaudit/content.js:85 — content.consent has cognitive complexity 20 (threshold 15). Drivers by points: if/else 3 (7 pts), loops 4 (6 pts), boolean chains 4, error handling 1 (3 pts) (nesting depth added 8). Of this number, 18 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · engine-page.acceptAnswer (cognitive 20) · ×1
  • engine-page.acceptAnswer (cognitive 20) app/src/main/assets/p2pshare/engine-page.js:748 — engine-page.acceptAnswer has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (8 pts), boolean chains 6, error handling 3 (4 pts), ternaries 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · engine-page.pumpFile (cognitive 20) · ×1
  • engine-page.pumpFile (cognitive 20) app/src/main/assets/p2pshare/engine-page.js:831 — engine-page.pumpFile has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 5, loops 2 (3 pts), error handling 1, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.findDash (cognitive 20) · ×1
  • page-state-bridge.findDash (cognitive 20) app/src/main/assets/webrequests/js/page-state-bridge.js:81 — page-state-bridge.findDash has cognitive complexity 20 (threshold 15). Drivers by points: error handling 3 (7 pts), if/else 6 (7 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 6). None of this is in the body itself: all 20 points belong to one function literal inside it that branches (line 85). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · bluesky.collectBskyVideos · ×1
  • bluesky.collectBskyVideos::visit (cognitive 20) app/src/main/assets/webrequests/js/parsers/bluesky.js:131 — bluesky.collectBskyVideos::visit has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 7, loops 2 (3 pts) (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · requests.parseHlsMasterChildren (cognitive 20) · ×1
  • requests.parseHlsMasterChildren (cognitive 20) app/src/main/assets/webrequests/js/requests.js:1654 — requests.parseHlsMasterChildren has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 2, error handling 1, loops 1 (nesting depth added 8). Of this number, 18 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · telegram.emitVideosFromHtml (cognitive 20) · ×1
  • telegram.emitVideosFromHtml (cognitive 20) app/src/main/assets/webrequests/js/parsers/telegram.js:148 — telegram.emitVideosFromHtml has cognitive complexity 20 (threshold 15). Drivers by points: boolean chains 11, if/else 3 (4 pts), ternaries 2 (4 pts), loops 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · spotify.extractSpotifyEmbedTracks (cognitive 20) · ×1
  • spotify.extractSpotifyEmbedTracks (cognitive 20) app/src/main/assets/webrequests/js/parsers/spotify.js:102 — spotify.extractSpotifyEmbedTracks has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 7, ternaries 2 (3 pts), loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · substack.entriesOfPost (cognitive 20) · ×1
  • substack.entriesOfPost (cognitive 20) app/src/main/assets/webrequests/js/parsers/substack.js:148 — substack.entriesOfPost has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 4 (7 pts), if/else 4 (6 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.transformUrl (cognitive 20) · ×1
  • background.transformUrl (cognitive 20) app/src/main/assets/youtube/background.js:707 — background.transformUrl has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 4, error handling 1 (2 pts), ternaries 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonManager.blockersFor (cognitive 19) · ×1
  • AddonManager.blockersFor (cognitive 19) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:832 — AddonManager.blockersFor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 5, ternaries 1 (3 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonPermissions.describe (cognitive 19) · ×1
  • AddonPermissions.describe (cognitive 19) app/src/main/java/com/solarized/firedown/addons/AddonPermissions.java:87 — AddonPermissions.describe has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (5 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · NavigationDelegate.onLoadRequest (cognitive 19) · ×1
  • NavigationDelegate.onLoadRequest (cognitive 19) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:2010 — NavigationDelegate.onLoadRequest has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 5 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GeckoInspectTask.prepareEntity (cognitive 19) · ×1
  • GeckoInspectTask.prepareEntity (cognitive 19) app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:238 — GeckoInspectTask.prepareEntity has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, ternaries 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · SecurityStateSheetDialogFragment.onCreateView (cognitive 19) · ×1
  • SecurityStateSheetDialogFragment.onCreateView (cognitive 19) app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:132 — SecurityStateSheetDialogFragment.onCreateView has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (8 pts), ternaries 6, boolean chains 4, error handling 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · BaseDownloadFragment.handleTaskFinish (cognitive 19) · ×1
  • BaseDownloadFragment.handleTaskFinish (cognitive 19) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:940 — BaseDownloadFragment.handleTaskFinish has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, ternaries 1 (2 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · PlaybackDebugInfo.appendTracks (cognitive 19) · ×1
  • PlaybackDebugInfo.appendTracks (cognitive 19) app/src/main/java/com/solarized/firedown/phone/player/PlaybackDebugInfo.java:116 — PlaybackDebugInfo.appendTracks has cognitive complexity 19 (threshold 15). Drivers by points: if/else 2 (6 pts), loops 3 (6 pts), ternaries 2 (6 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonDetailFragment.bindOptional (cognitive 19) · ×1
  • AddonDetailFragment.bindOptional (cognitive 19) app/src/main/java/com/solarized/firedown/settings/AddonDetailFragment.java:337 — AddonDetailFragment.bindOptional has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 5 (6 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CloudBackupManager.loadStatus (cognitive 19) · ×1
  • CloudBackupManager.loadStatus (cognitive 19) app/src/main/java/com/solarized/firedown/sync/CloudBackupManager.java:511 — CloudBackupManager.loadStatus has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), error handling 1 (3 pts), loops 1 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadItemAdapter.applyGridTileGround (cognitive 19) · ×1
  • DownloadItemAdapter.applyGridTileGround (cognitive 19) app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java:1052 — DownloadItemAdapter.applyGridTileGround has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 6 (10 pts), if/else 7, boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · JsonHelper.parse (cognitive 19) · ×1
  • JsonHelper.parse (cognitive 19) app/src/main/java/com/solarized/firedown/utils/JsonHelper.java:26 — JsonHelper.parse has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 5, error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateDownloader.inFlightLocked (cognitive 19) · ×1
  • UpdateDownloader.inFlightLocked (cognitive 19) app/src/main/java/com/solarized/firedown/UpdateDownloader.java:432 — UpdateDownloader.inFlightLocked has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (18 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · UpdateWorker.doWork (cognitive 19) · ×1
  • UpdateWorker.doWork (cognitive 19) app/src/main/java/com/solarized/firedown/UpdateWorker.java:56 — UpdateWorker.doWork has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (10 pts), ternaries 2 (7 pts), boolean chains 1, error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content.cardHtml (cognitive 19) · ×1
  • content.cardHtml (cognitive 19) app/src/debug/assets/siteaudit/content.js:240 — content.cardHtml has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 4 (5 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · engine-page.reportTransport (cognitive 19) · ×1
  • engine-page.reportTransport (cognitive 19) app/src/main/assets/p2pshare/engine-page.js:410 — engine-page.reportTransport has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 10, if/else 8, ternaries 1. Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 422, 412, 415). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · dailymotion.maybeEmitDailymotionEmbed (cognitive 19) · ×1
  • dailymotion.maybeEmitDailymotionEmbed (cognitive 19) app/src/main/assets/webrequests/js/parsers/dailymotion.js:405 — dailymotion.maybeEmitDailymotionEmbed has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 2, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · deezer.listenerDeezerGateway (cognitive 19) · ×1
  • deezer.listenerDeezerGateway (cognitive 19) app/src/main/assets/webrequests/js/parsers/deezer.js:166 — deezer.listenerDeezerGateway has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (7 pts), ternaries 4 (7 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). None of this is in the body itself: all 19 points belong to one function literal inside it that branches (line 167). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · requests.classifyXhr (cognitive 19) · ×1
  • requests.classifyXhr (cognitive 19) app/src/main/assets/webrequests/js/requests.js:621 — requests.classifyXhr has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.nameCapturedClip (cognitive 19) · ×1
  • requests.nameCapturedClip (cognitive 19) app/src/main/assets/webrequests/js/requests.js:925 — requests.nameCapturedClip has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 6, ternaries 2, error handling 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · twitter.parseTwitterSsrStreamValues (cognitive 19) · ×1
  • twitter.parseTwitterSsrStreamValues (cognitive 19) app/src/main/assets/webrequests/js/parsers/twitter.js:717 — twitter.parseTwitterSsrStreamValues has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (11 pts), error handling 1 (3 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · twitter.collectTwitterSsrBodies · ×1
  • twitter.collectTwitterSsrBodies::walk (cognitive 19) app/src/main/assets/webrequests/js/parsers/twitter.js:774 — twitter.collectTwitterSsrBodies::walk has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 4, error handling 1 (3 pts), loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.extractUrlParams (cognitive 19) · ×1
  • background.extractUrlParams (cognitive 19) app/src/main/assets/youtube/background.js:638 — background.extractUrlParams has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.replaceUrlParams (cognitive 19) · ×1
  • background.replaceUrlParams (cognitive 19) app/src/main/assets/youtube/background.js:665 — background.replaceUrlParams has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 2, loops 1 (2 pts), error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AutoCompleteEditText.onFocusChanged (cognitive 18) · ×1
  • AutoCompleteEditText.onFocusChanged (cognitive 18) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:387 — AutoCompleteEditText.onFocusChanged has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 1, error handling 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · 4.afterTextChanged (cognitive 18) · ×1
  • 4.afterTextChanged (cognitive 18) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteEditText.java:895 — 4.afterTextChanged has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 7, ternaries 1 (2 pts) (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · AutoCompleteSearch.mostVisited (cognitive 18) · ×1
  • AutoCompleteSearch.mostVisited (cognitive 18) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:127 — AutoCompleteSearch.mostVisited has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FaviconStore.looksLikeImage (cognitive 18) · ×1
  • FaviconStore.looksLikeImage (cognitive 18) REDACTED:231 — FaviconStore.looksLikeImage has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 10, if/else 8. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · NestedGeckoView.onTouchEvent (cognitive 18) · ×1
  • NestedGeckoView.onTouchEvent (cognitive 18) app/src/main/java/com/solarized/firedown/geckoview/NestedGeckoView.java:99 — NestedGeckoView.onTouchEvent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, match/switch 1 (nesting depth added 7). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · PoTokenGenerator.ensureReady (cognitive 18) · ×1
  • PoTokenGenerator.ensureReady (cognitive 18) app/src/main/java/com/solarized/firedown/geckoview/PoTokenGenerator.java:714 — PoTokenGenerator.ensureReady has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 3, error handling 2, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AudioEncodeTask.stoppableRun (cognitive 18) · ×1
  • AudioEncodeTask.stoppableRun (cognitive 18) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:41 — AudioEncodeTask.stoppableRun has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 3, ternaries 2 (3 pts), error handling 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · P2pLanServer.findLanAddress (cognitive 18) · ×1
  • P2pLanServer.findLanAddress (cognitive 18) app/src/main/java/com/solarized/firedown/p2pshare/P2pLanServer.java:359 — P2pLanServer.findLanAddress has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (11 pts), boolean chains 3, loops 2 (3 pts), error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonPromptSheetDialogFragment.bind (cognitive 18) · ×1
  • AddonPromptSheetDialogFragment.bind (cognitive 18) app/src/main/java/com/solarized/firedown/phone/dialogs/AddonPromptSheetDialogFragment.java:86 — AddonPromptSheetDialogFragment.bind has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 5 (6 pts), if/else 5, boolean chains 4, loops 1 (2 pts), match/switch 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · BrowserOptionFragment.submitListPreservingScroll (cognitive 18) · ×1
  • BrowserOptionFragment.submitListPreservingScroll (cognitive 18) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionFragment.java:414 — BrowserOptionFragment.submitListPreservingScroll has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, loops 2, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · MediaViewerFragment.onViewCreated (cognitive 18) · ×1
  • MediaViewerFragment.onViewCreated (cognitive 18) app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:738 — MediaViewerFragment.onViewCreated has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 2 (4 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Fmp4Muxer.writeFragment (cognitive 18) · ×1
  • Fmp4Muxer.writeFragment (cognitive 18) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:287 — Fmp4Muxer.writeFragment has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 3, ternaries 1 (3 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SyncSettingsFragment.updateState (cognitive 18) · ×1
  • SyncSettingsFragment.updateState (cognitive 18) app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:349 — SyncSettingsFragment.updateState has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 5 (11 pts), if/else 5 (6 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · S3Client.classify (cognitive 18) · ×1
  • S3Client.classify (cognitive 18) REDACTED:835 — S3Client.classify has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (8 pts), ternaries 5 (8 pts), boolean chains 1, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · InfoAdapter.onBindViewHolder (cognitive 18) · ×1
  • InfoAdapter.onBindViewHolder (cognitive 18) app/src/main/java/com/solarized/firedown/ui/adapters/InfoAdapter.java:115 — InfoAdapter.onBindViewHolder has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (14 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · BookmarkHtml.parse (cognitive 18) · ×1
  • BookmarkHtml.parse (cognitive 18) app/src/main/java/com/solarized/firedown/utils/BookmarkHtml.java:86 — BookmarkHtml.parse has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), error handling 1 (3 pts), ternaries 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · IntentSanitizer.stripUnsavableExtras (cognitive 18) · ×1
  • IntentSanitizer.stripUnsavableExtras (cognitive 18) app/src/main/java/com/solarized/firedown/utils/IntentSanitizer.java:85 — IntentSanitizer.stripUnsavableExtras has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (12 pts), error handling 2 (3 pts), loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · engine-page.sanitizeIceServers (cognitive 18) · ×1
  • engine-page.sanitizeIceServers (cognitive 18) app/src/main/assets/p2pshare/engine-page.js:234 — engine-page.sanitizeIceServers has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (8 pts), ternaries 2 (5 pts), boolean chains 4, loops 1 (nesting depth added 7). Of this number, 17 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content-script.queueJsonClips (cognitive 18) · ×1
  • content-script.queueJsonClips (cognitive 18) app/src/main/assets/webrequests/js/content-script.js:3702 — content-script.queueJsonClips has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (9 pts), loops 4 (7 pts), boolean chains 1, error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · apple-podcasts.processApplePodcastEpisode (cognitive 18) · ×1
  • apple-podcasts.processApplePodcastEpisode (cognitive 18) app/src/main/assets/webrequests/js/parsers/apple-podcasts.js:83 — apple-podcasts.processApplePodcastEpisode has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 5, ternaries 2, error handling 1, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · requests.browser.webRequest.onHeadersReceived.addListener() (cognitive 18) · ×1
  • requests.browser.webRequest.onHeadersReceived.addListener() (cognitive 18) app/src/main/assets/webrequests/js/requests.js:1493 — requests.browser.webRequest.onHeadersReceived.addListener() has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 3, ternaries 1 (2 pts), error handling 1 (nesting depth added 3). Most of this is not in the body itself: 7 of the 18 points are its own statements and the rest belongs to 4 function items inside it that branch (finish, a function literal at line 1532, a function literal at line 1556, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · instagram.buildInstagramItemVariants (cognitive 18) · ×1
  • instagram.buildInstagramItemVariants (cognitive 18) app/src/main/assets/webrequests/js/parsers/instagram.js:264 — instagram.buildInstagramItemVariants has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 5 (7 pts), loops 1, ternaries 1 (nesting depth added 2). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · page-state.claimUrlsOf (cognitive 18) · ×1
  • page-state.claimUrlsOf (cognitive 18) app/src/main/assets/webrequests/js/parsers/page-state.js:37 — page-state.claimUrlsOf has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · background.browser.webRequest.onBeforeRequest.addListener() (cognitive 18) · ×1
  • background.browser.webRequest.onBeforeRequest.addListener() (cognitive 18) app/src/main/assets/youtube/background.js:2822 — background.browser.webRequest.onBeforeRequest.addListener() has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, loops 2, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · AddonPermissions.siteLines (cognitive 17) · ×1
  • AddonPermissions.siteLines (cognitive 17) app/src/main/java/com/solarized/firedown/addons/AddonPermissions.java:319 — AddonPermissions.siteLines has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AutoCompleteSearch.addOpenTabs (cognitive 17) · ×1
  • AutoCompleteSearch.addOpenTabs (cognitive 17) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:357 — AutoCompleteSearch.addOpenTabs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 4, ternaries 2 (4 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · LegacyShortcutsMigrator.runOnDiskThread (cognitive 17) · ×1
  • LegacyShortcutsMigrator.runOnDiskThread (cognitive 17) app/src/main/java/com/solarized/firedown/data/LegacyShortcutsMigrator.java:76 — LegacyShortcutsMigrator.runOnDiskThread has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 4 (8 pts), if/else 3 (4 pts), error handling 2 (3 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FFmpegMetaData.isValidMedia (cognitive 17) · ×1
  • FFmpegMetaData.isValidMedia (cognitive 17) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaData.java:156 — FFmpegMetaData.isValidMedia has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 4, loops 1 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DownloadTask.onRunComplete (cognitive 17) · ×1
  • DownloadTask.onRunComplete (cognitive 17) app/src/main/java/com/solarized/firedown/manager/DownloadTask.java:247 — DownloadTask.onRunComplete has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FFmpegMuxStrategy.playlistState (cognitive 17) · ×1
  • FFmpegMuxStrategy.playlistState (cognitive 17) app/src/main/java/com/solarized/firedown/manager/FFmpegMuxStrategy.java:372 — FFmpegMuxStrategy.playlistState has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SecurityStateSheetDialogFragment.renderBanner (cognitive 17) · ×1
  • SecurityStateSheetDialogFragment.renderBanner (cognitive 17) app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:562 — SecurityStateSheetDialogFragment.renderBanner has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (8 pts), ternaries 5 (7 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · BrowserFragment.onFocusChanged (cognitive 17) · ×1
  • BrowserFragment.onFocusChanged (cognitive 17) app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1818 — BrowserFragment.onFocusChanged has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (17 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · GifMakerFragment.runThumbnailWorker (cognitive 17) · ×1
  • GifMakerFragment.runThumbnailWorker (cognitive 17) app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:358 — GifMakerFragment.runThumbnailWorker has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), error handling 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Fmp4Muxer.readTfdt (cognitive 17) · ×1
  • Fmp4Muxer.readTfdt (cognitive 17) app/src/main/java/com/solarized/firedown/sabr/Fmp4Muxer.java:507 — Fmp4Muxer.readTfdt has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (12 pts), ternaries 1 (3 pts), boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonDetailFragment.onCreatePreferences (cognitive 17) · ×1
  • AddonDetailFragment.onCreatePreferences (cognitive 17) app/src/main/java/com/solarized/firedown/settings/AddonDetailFragment.java:97 — AddonDetailFragment.onCreatePreferences has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 4, ternaries 1. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · StorageBarView.onDraw (cognitive 17) · ×1
  • StorageBarView.onDraw (cognitive 17) app/src/main/java/com/solarized/firedown/ui/StorageBarView.java:82 — StorageBarView.onDraw has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), ternaries 2 (4 pts), loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.readPageState (cognitive 17) · ×1
  • page-state-bridge.readPageState (cognitive 17) app/src/main/assets/webrequests/js/page-state-bridge.js:304 — page-state-bridge.readPageState has cognitive complexity 17 (threshold 15). Drivers by points: error handling 4 (7 pts), if/else 4 (7 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · common.sendSubtitles (cognitive 17) · ×1
  • common.sendSubtitles (cognitive 17) app/src/main/assets/webrequests/js/parsers/common.js:557 — common.sendSubtitles has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, error handling 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · apple-podcasts.dispatchAppleEpisodes (cognitive 17) · ×1
  • apple-podcasts.dispatchAppleEpisodes (cognitive 17) app/src/main/assets/webrequests/js/parsers/apple-podcasts.js:273 — apple-podcasts.dispatchAppleEpisodes has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (9 pts), boolean chains 3, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · requests.responseTotalBytes (cognitive 17) · ×1
  • requests.responseTotalBytes (cognitive 17) app/src/main/assets/webrequests/js/requests.js:413 — requests.responseTotalBytes has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 8, if/else 6, ternaries 2 (3 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · requests.isManifestSniffCandidate (cognitive 17) · ×1
  • requests.isManifestSniffCandidate (cognitive 17) app/src/main/assets/webrequests/js/requests.js:1448 — requests.isManifestSniffCandidate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 7 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · requests.handleSnapshotFetch (cognitive 17) · ×1
  • requests.handleSnapshotFetch (cognitive 17) app/src/main/assets/webrequests/js/requests.js:2460 — requests.handleSnapshotFetch has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 5, error handling 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · facebook.isFacebookVideoNode (cognitive 17) · ×1
  • facebook.isFacebookVideoNode (cognitive 17) app/src/main/assets/webrequests/js/parsers/facebook.js:95 — facebook.isFacebookVideoNode has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tiktok.handleTikTokItemList · ×1
  • tiktok.handleTikTokItemList::walk (cognitive 17) app/src/main/assets/webrequests/js/parsers/tiktok.js:351 — tiktok.handleTikTokItemList::walk has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 4, loops 2 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (tiktok.handleTikTokItemList) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · instagram.matchObjectEnd (cognitive 17) · ×1
  • instagram.matchObjectEnd (cognitive 17) app/src/main/assets/webrequests/js/parsers/instagram.js:1056 — instagram.matchObjectEnd has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · rumble.collectRumbleMp4 (cognitive 17) · ×1
  • rumble.collectRumbleMp4 (cognitive 17) app/src/main/assets/webrequests/js/parsers/rumble.js:65 — rumble.collectRumbleMp4 has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 6, if/else 3 (5 pts), ternaries 3 (5 pts), loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · videee.collectVideeeVideos · ×1
  • videee.collectVideeeVideos::visit (cognitive 17) app/src/main/assets/webrequests/js/parsers/videee.js:93 — videee.collectVideeeVideos::visit has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 6, if/else 5 (6 pts), loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · substack.listenerSubstackMedia (cognitive 17) · ×1
  • substack.listenerSubstackMedia (cognitive 17) app/src/main/assets/webrequests/js/parsers/substack.js:305 — substack.listenerSubstackMedia has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 7, if/else 5 (6 pts), ternaries 3, loops 1 (nesting depth added 1). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 309). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · AddonManager.install (cognitive 16) · ×1
  • AddonManager.install (cognitive 16) app/src/main/java/com/solarized/firedown/addons/AddonManager.java:1130 — AddonManager.install has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BrowserDownloadRepository.addValue (cognitive 16) · ×1
  • BrowserDownloadRepository.addValue (cognitive 16) app/src/main/java/com/solarized/firedown/data/repository/BrowserDownloadRepository.java:160 — BrowserDownloadRepository.addValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (13 pts), loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ContentDelegate.onExternalResponse (cognitive 16) · ×1
  • ContentDelegate.onExternalResponse (cognitive 16) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1020 — ContentDelegate.onExternalResponse has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 2 (4 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · NestedGeckoView.updateInputResult (cognitive 16) · ×1
  • NestedGeckoView.updateInputResult (cognitive 16) app/src/main/java/com/solarized/firedown/geckoview/NestedGeckoView.java:191 — NestedGeckoView.updateInputResult has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · P2pShareController.acceptOffer (cognitive 16) · ×1
  • P2pShareController.acceptOffer (cognitive 16) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:1548 — P2pShareController.acceptOffer has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (8 pts), boolean chains 6, error handling 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · P2pShareController.acquireTransferLocks (cognitive 16) · ×1
  • P2pShareController.acquireTransferLocks (cognitive 16) app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java:2169 — P2pShareController.acquireTransferLocks has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 2, error handling 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BrowserOptionVariantsFragment.dispatchDownload (cognitive 16) · ×1
  • BrowserOptionVariantsFragment.dispatchDownload (cognitive 16) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionVariantsFragment.java:205 — BrowserOptionVariantsFragment.dispatchDownload has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 1 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PopupBrowserSheetDialogFragment.onViewCreated (cognitive 16) · ×1
  • PopupBrowserSheetDialogFragment.onViewCreated (cognitive 16) app/src/main/java/com/solarized/firedown/phone/dialogs/PopupBrowserSheetDialogFragment.java:761 — PopupBrowserSheetDialogFragment.onViewCreated has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 1, loops 1, ternaries 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SecurityStateSheetDialogFragment.renderBlockers (cognitive 16) · ×1
  • SecurityStateSheetDialogFragment.renderBlockers (cognitive 16) app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java:325 — SecurityStateSheetDialogFragment.renderBlockers has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (8 pts), loops 5 (7 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BusyPreference.onBindViewHolder (cognitive 16) · ×1
  • BusyPreference.onBindViewHolder (cognitive 16) app/src/main/java/com/solarized/firedown/settings/ui/BusyPreference.java:80 — BusyPreference.onBindViewHolder has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (14 pts), ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonsFragment.renderInstalled (cognitive 16) · ×1
  • AddonsFragment.renderInstalled (cognitive 16) app/src/main/java/com/solarized/firedown/settings/AddonsFragment.java:203 — AddonsFragment.renderInstalled has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), loops 3 (4 pts), boolean chains 2, ternaries 1 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · BrowserTabsAdapter.onBindViewHolder (cognitive 16) · ×1
  • BrowserTabsAdapter.onBindViewHolder (cognitive 16) app/src/main/java/com/solarized/firedown/ui/adapters/BrowserTabsAdapter.java:235 — BrowserTabsAdapter.onBindViewHolder has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 1 (3 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BookmarkHtml.export (cognitive 16) · ×1
  • BookmarkHtml.export (cognitive 16) app/src/main/java/com/solarized/firedown/utils/BookmarkHtml.java:55 — BookmarkHtml.export has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), ternaries 1 (3 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · StoragePaths.findRemovableVolumeRoot (cognitive 16) · ×1
  • StoragePaths.findRemovableVolumeRoot (cognitive 16) app/src/main/java/com/solarized/firedown/StoragePaths.java:211 — StoragePaths.findRemovableVolumeRoot has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 2, error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content-script.metadataFor (cognitive 16) · ×1
  • content-script.metadataFor (cognitive 16) app/src/main/assets/webrequests/js/content-script.js:3341 — content-script.metadataFor has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), boolean chains 3, error handling 1 (2 pts), loops 1, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · content-script.scrapeJsonLdMedia (cognitive 16) · ×1
  • content-script.scrapeJsonLdMedia (cognitive 16) app/src/main/assets/webrequests/js/content-script.js:3634 — content-script.scrapeJsonLdMedia has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 5, if/else 4 (5 pts), loops 3 (4 pts), error handling 1 (2 pts) (nesting depth added 3). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to one function item inside it that branches (visit). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · content-script.scrapeJsonScripts (cognitive 16) · ×1
  • content-script.scrapeJsonScripts (cognitive 16) app/src/main/assets/webrequests/js/content-script.js:3670 — content-script.scrapeJsonScripts has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), boolean chains 3, error handling 2 (3 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · page-state-bridge.repToPlain (cognitive 16) · ×1
  • page-state-bridge.repToPlain (cognitive 16) app/src/main/assets/webrequests/js/page-state-bridge.js:113 — page-state-bridge.repToPlain has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 6 (7 pts), if/else 4 (5 pts), boolean chains 3, error handling 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · page-state-bridge.extractMega (cognitive 16) · ×1
  • page-state-bridge.extractMega (cognitive 16) app/src/main/assets/webrequests/js/page-state-bridge.js:1833 — page-state-bridge.extractMega has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 7, if/else 6, error handling 2, ternaries 1. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · js-literal.parseJsValue (cognitive 16) · ×1
  • js-literal.parseJsValue (cognitive 16) app/src/main/assets/webrequests/js/parsers/js-literal.js:16 — js-literal.parseJsValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · twitter.scanForMediaArray (cognitive 16) · ×1
  • twitter.scanForMediaArray (cognitive 16) app/src/main/assets/webrequests/js/parsers/twitter.js:207 — twitter.scanForMediaArray has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · twitch.fetchTwitchLiveStream (cognitive 16) · ×1
  • twitch.fetchTwitchLiveStream (cognitive 16) app/src/main/assets/webrequests/js/parsers/twitch.js:229 — twitch.fetchTwitchLiveStream has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 9, if/else 5 (6 pts), error handling 1 (nesting depth added 1). Of this number, 11 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · background.sha1Pure (cognitive 16) · ×1
  • background.sha1Pure (cognitive 16) app/src/main/assets/youtube/background.js:814 — background.sha1Pure has cognitive complexity 16 (threshold 15). Drivers by points: loops 7 (10 pts), if/else 4 (6 pts) (nesting depth added 5). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D4 · Code Duplication · Near-duplicate member pair (59 shared lines) · ×1
  • Near-duplicate member pair (59 shared lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:290-512 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:224-386 — These two members are variants of one another: 59 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (53 shared lines) · ×1
  • Near-duplicate member pair (53 shared lines) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:41 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:41-146 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:41-167 — These two members are variants of one another: 53 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (38 shared lines) · ×1
  • Near-duplicate member pair (38 shared lines) app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:79 — app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:79-153 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:407-540 — These two members are variants of one another: 38 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Members sharing a duplicated core (9 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (9 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:44 — app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:44-74 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:94-120 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:141-207 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:237-281 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:305-339 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:349-367 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:378-400 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:414-448 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:511-533 — These 9 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 9 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 9 times.
D4 · Code Duplication · Members sharing a duplicated core (6 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (6 members, 50+ identical tokens) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:28 — app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:28-52 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:69-109 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:111-151 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:161-195 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:198-237 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:240-274 — These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
D4 · Code Duplication · Edited copy of a member (81 corresponding lines) · ×1
  • Edited copy of a member (81 corresponding lines) app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:36 — app/src/main/java/com/solarized/firedown/manager/tasks/InSafeTask.java:36-117 | app/src/main/java/com/solarized/firedown/manager/tasks/OutSafeTask.java:35-115 — These two members are one piece of code written twice and then edited apart: 81 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (48 corresponding lines) · ×1
  • Edited copy of a member (48 corresponding lines) app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:108 — app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:108-157 | app/src/main/java/com/solarized/firedown/manager/DownloadRequest.java:162-209 — These two members are one piece of code written twice and then edited apart: 48 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (72 corresponding lines) · ×1
  • Edited copy of a member (72 corresponding lines) app/src/main/java/com/solarized/firedown/glide/FFmpegGlideUrlDecoder.java:42 — app/src/main/java/com/solarized/firedown/glide/FFmpegGlideUrlDecoder.java:42-113 | app/src/main/java/com/solarized/firedown/glide/FFmpegUriDecoder.java:55-154 — These two members are one piece of code written twice and then edited apart: 72 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (53 corresponding lines) · ×1
  • Edited copy of a member (53 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:212 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:212-287 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:140-192 — These two members are one piece of code written twice and then edited apart: 53 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (55 corresponding lines) · ×1
  • Edited copy of a member (55 corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:162 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:162-219 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:70-124 — These two members are one piece of code written twice and then edited apart: 55 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (26 corresponding lines) · ×1
  • Edited copy of a member (26 corresponding lines) app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:679 — app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:679-704 | app/src/main/java/com/solarized/firedown/settings/CloudBackupFileAdapter.java:779-810 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (28 corresponding lines) · ×1
  • Edited copy of a member (28 corresponding lines) app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:572 — app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:572-610 | app/src/main/java/com/solarized/firedown/sync/VaultBackupWorker.java:622-649 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 27+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 27+ corresponding lines) app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:112 — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:112-139 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegDownloader.java:154-180 | app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegMetaDataReader.java:124-154 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 27 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (32 corresponding lines) · ×1
  • Edited copy of a member (32 corresponding lines) app/src/main/java/com/solarized/firedown/utils/WebUtils.java:342 — app/src/main/java/com/solarized/firedown/utils/WebUtils.java:342-377 | app/src/main/java/com/solarized/firedown/utils/WebUtils.java:450-481 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 13+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 13+ corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/prompt/PromptViewFactory.java:128 — app/src/main/java/com/solarized/firedown/geckoview/prompt/PromptViewFactory.java:128-140 | app/src/main/java/com/solarized/firedown/geckoview/prompt/PromptViewFactory.java:215-229 | app/src/main/java/com/solarized/firedown/geckoview/prompt/PromptViewFactory.java:330-345 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 17+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 17+ corresponding lines) app/src/main/java/com/solarized/firedown/phone/dialogs/CancelOperationDialogFragment.java:20 — app/src/main/java/com/solarized/firedown/phone/dialogs/CancelOperationDialogFragment.java:20-41 | app/src/main/java/com/solarized/firedown/phone/dialogs/DeleteLoginDialogFragment.java:21-37 | app/src/main/java/com/solarized/firedown/phone/dialogs/EnrollDialogFragment.java:60-82 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 15+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 15+ corresponding lines) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:371 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:371-385 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:103-117 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:352-384 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 14+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 14+ corresponding lines) REDACTED:271 — REDACTED:271-284 | REDACTED:280-293 | REDACTED:175-188 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 19+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 19+ corresponding lines) app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewBehavior.java:58 — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteViewBehavior.java:58-76 | app/src/main/java/com/solarized/firedown/utils/FindViewUtils.java:15-33 | app/src/main/java/com/solarized/firedown/utils/FindViewUtils.java:36-54 | app/src/main/java/com/solarized/firedown/utils/FindViewUtils.java:75-93 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (8 members, 12+ corresponding lines) · ×1
  • Edited copies of one member (8 members, 12+ corresponding lines) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:391 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:391-402 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:434-449 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:454-466 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:470-483 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:488-500 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:504-517 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:521-537 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:558-571 — These 8 members are one piece of code written 8 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 8 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 9+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 9+ corresponding lines) app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:164 — app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:164-172 | app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:181-189 | app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:239-247 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (34–45 lines × 2) · ×1
  • Duplicated block (34–45 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:417 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:417-461 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:273-306 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:417` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (31 lines × 2) · ×1
  • Duplicated block (31 lines × 2) app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:43 — app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:43-73 | app/src/main/java/com/solarized/firedown/glide/svg/SvgUriDecoder.java:47-77 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:43` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/glide/svg/SvgUriDecoder.java:45` calls `get`, `FileInputStream` and `app/src/main/java/com/solarized/firedown/glide/svg/SvgInputStreamDecoder.java:42` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (28–29 lines × 2) · ×1
  • Duplicated block (28–29 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:558 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:558-586 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:287-314 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:286` calls `clearPrivate` and `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:550` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (27–29 lines × 2) · ×1
  • Duplicated block (27–29 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:234 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:234-262 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:150-176 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:265` calls `setMostVisitedClickListener`, `openUri`, `setMostVisitedRemoveListener` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:178` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (25–28 lines × 2) · ×1
  • Duplicated block (25–28 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:137 — app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:137-161 | app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java:215-242 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/GifMakerFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 47 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/FrameGrabberFragment.java:137` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (21–26 lines × 2) · ×1
  • Duplicated block (21–26 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:488 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:488-513 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:182-202 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:488` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:487` calls `d` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:181` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (11–26 lines × 2) · ×1
  • Duplicated block (11–26 lines × 2) app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:219 — app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:219-229 | app/src/main/java/com/solarized/firedown/glide/FFmpegUriDecoder.java:118-143 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:219` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (25–26 lines × 2) · ×1
  • Duplicated block (25–26 lines × 2) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:83 — app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:83-108 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:122-146 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:83` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (24–25 lines × 2) · ×1
  • Duplicated block (24–25 lines × 2) app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:613 — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:613-636 | app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:247-271 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 107 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:613` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:611` calls `setPendingRestoreIndex` and `app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java:245` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (17–25 lines × 2) · ×1
  • Duplicated block (17–25 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1586 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1586-1602 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1626-1650 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1586` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (23 lines × 2) · ×1
  • Duplicated block (23 lines × 2) app/src/main/java/com/solarized/firedown/glide/FFmpegGlideUrlDecoder.java:76 — app/src/main/java/com/solarized/firedown/glide/FFmpegGlideUrlDecoder.java:76-98 | app/src/main/java/com/solarized/firedown/glide/FFmpegUriDecoder.java:109-131 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/glide/FFmpegUriDecoder.java:138` calls `obtain` and `app/src/main/java/com/solarized/firedown/glide/FFmpegGlideUrlDecoder.java:100` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (18–23 lines × 2) · ×1
  • Duplicated block (18–23 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:163 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:163-185 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:71-88 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:163` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (19–21 lines × 2) · ×1
  • Duplicated block (19–21 lines × 2) app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:58 — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:58-78 | app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java:58-76 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java` and `app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 66 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (20–21 lines × 2) · ×1
  • Duplicated block (20–21 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:197 — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:197-216 | app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java:100-120 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:197` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (11–20 lines × 2) · ×1
  • Duplicated block (11–20 lines × 2) app/src/main/java/com/solarized/firedown/GlideHelper.java:1009 — app/src/main/java/com/solarized/firedown/GlideHelper.java:1009-1028 | app/src/main/java/com/solarized/firedown/GlideHelper.java:1168-1178 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/GlideHelper.java:1009` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (19 lines × 2) · ×1
  • Duplicated block (19 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:70 — app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:70-88 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:74-92 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java` and `app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit. Note first that the copies are not typed on the same thing: the declarations holding them bind `diffCallback` to `DiffUtil.ItemCallback<WebBookmarkEntity>` in one and `DiffUtil.ItemCallback<Object>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (13–18 lines × 2) · ×1
  • Duplicated block (13–18 lines × 2) app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:987 — app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:987-1004 | app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1007-1019 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:987` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:982` calls `cancelAll`, `d` and `app/src/main/java/com/solarized/firedown/manager/DownloadEngine.java:1004` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (15–17 lines × 2) · ×1
  • Duplicated block (15–17 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:271 — app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:271-287 | app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:178-192 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 163 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:271` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java:265` calls `setMostVisitedClickListener`, `openUri`, `setMostVisitedRemoveListener` and `app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java:176` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (15–16 lines × 2) · ×1
  • Duplicated block (15–16 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:896 — app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:896-910 | app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:200-215 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/BaseDownloadFragment.java:896` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–16 lines × 2) · ×1
  • Duplicated block (8–16 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:276 — app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:276-283 | app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:879-894 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:276` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java:895` calls `signature`, `ObjectKey`, `hashCode` and `app/src/main/java/com/solarized/firedown/phone/fragments/ImageViewerFragment.java:284` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (9–15 lines × 3) · ×1
  • Duplicated block (9–15 lines × 3) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:427 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:427-435 | app/src/main/java/com/solarized/firedown/phone/fragments/LockFragment.java:204-218 | app/src/main/java/com/solarized/firedown/phone/fragments/TabsArchiveFragment.java:269-277 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionHolderSheetDialogFragment.java:427` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14–15 lines × 2) · ×1
  • Duplicated block (14–15 lines × 2) app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:123 — app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:123-137 | app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:82-95 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:123` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/manager/MegaStrategy.java:138` calls `isEmpty`, `getExtension`, `getName` and `app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:96` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (10–14 lines × 2) · ×1
  • Duplicated block (10–14 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1273 — app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1273-1282 | app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1503-1516 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (12–14 lines × 2) · ×1
  • Duplicated block (12–14 lines × 2) app/src/main/java/com/solarized/firedown/phone/dialogs/PlaybackSpeedSheetDialogFragment.java:110 — app/src/main/java/com/solarized/firedown/phone/dialogs/PlaybackSpeedSheetDialogFragment.java:110-121 | app/src/main/java/com/solarized/firedown/phone/dialogs/SubtitleSheetDialogFragment.java:142-155 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (11–13 lines × 2) · ×1
  • Duplicated block (11–13 lines × 2) app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomNavigationBar.java:285 — app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomNavigationBar.java:285-295 | app/src/main/java/com/solarized/firedown/geckoview/toolbar/BottomProgressView.java:107-119 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (12 lines × 3) · ×1
  • Duplicated block (12 lines × 3) app/src/main/java/com/solarized/firedown/data/repository/DownloadDataRepository.java:103 — app/src/main/java/com/solarized/firedown/data/repository/DownloadDataRepository.java:103-114 | app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:148-159 | app/src/main/java/com/solarized/firedown/data/repository/WebHistoryDataRepository.java:58-69 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (8–11 lines × 4) · ×1
  • Duplicated block (8–11 lines × 4) app/src/main/java/com/solarized/firedown/settings/AddonOptionsFragment.java:58 — app/src/main/java/com/solarized/firedown/settings/AddonOptionsFragment.java:58-65 | app/src/main/java/com/solarized/firedown/settings/FeedbackFragment.java:88-98 | app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:124-134 | app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java:94-104 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java` and `app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 55 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (7–11 lines × 3) · ×1
  • Duplicated block (7–11 lines × 3) app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:505 — app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:505-511 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:522-532 | app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:559-565 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind `prompt` to `TextPrompt` in one and `ButtonPrompt` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (10–11 lines × 3) · ×1
  • Duplicated block (10–11 lines × 3) app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:77 — app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:77-87 | app/src/main/java/com/solarized/firedown/phone/dialogs/RenameFileDialog.java:98-107 | app/src/main/java/com/solarized/firedown/phone/dialogs/SaveFileDialog.java:138-147 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserDownloadDialogFragment.java:77` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (9–11 lines × 2) · ×1
  • Duplicated block (9–11 lines × 2) app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:437 — app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:437-447 | app/src/main/java/com/solarized/firedown/settings/AboutFragment.java:221-229 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/UpdateAvailableSheet.java:437` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–11 lines × 2) · ×1
  • Duplicated block (10–11 lines × 2) app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:130 — app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:130-140 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:491-500 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java` and `app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:130` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/settings/SecurityFragment.java:120` calls `equals`, `getBoolean`, `setWebAssembly` and `app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:487` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (10 lines × 6) · ×1
  • Duplicated block (10 lines × 6) app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:38 — app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:38-47 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:85-94 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:124-133 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:171-180 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:213-222 | app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:250-259 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:38` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:83` calls `getAction` and `app/src/main/java/com/solarized/firedown/utils/NavigationUtils.java:211` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (6–10 lines × 3) · ×1
  • Duplicated block (6–10 lines × 3) app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:61 — app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:61-70 | app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java:81-86 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:85-90 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/ui/adapters/WebBookmarkAdapter.java` and `app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (13–14 lines × 2) · ×1
  • Duplicated block (13–14 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:417 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:417-429 | app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:193-206 — before extracting anything, compare `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 63 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:417` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:429` calls `stopActionMode`, `promptDeleteGrant`, `getEntities` and `app/src/main/java/com/solarized/firedown/phone/fragments/VaultFragment.java:206` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (7–8 lines × 2) · ×1
  • Duplicated block (7–8 lines × 2) app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:648 — app/src/main/java/com/solarized/firedown/phone/fragments/DownloadFragment.java:648-654 | app/src/main/java/com/solarized/firedown/settings/SettingsFragment.java:680-687 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (7–9 lines × 2) · ×1
  • Duplicated block (7–9 lines × 2) app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:70 — app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:70-78 | app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:88-94 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sync/model/BookmarkDoc.java:70` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (7 lines × 9) · ×1
  • Duplicated block (7 lines × 9) app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:46 — app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:46-52 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:96-102 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:143-149 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:239-245 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:307-313 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:351-357 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:380-386 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:416-422 | app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:513-519 — all 9 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `app/src/main/java/com/solarized/firedown/sabr/SabrMessages.java:46` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (6–7 lines × 2) · ×1
  • Duplicated block (6–7 lines × 2) app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:180 — app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:180-186 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:242-247 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:248` calls `setOnClickListener` and `app/src/main/java/com/solarized/firedown/ui/adapters/TabArchiveAdapter.java:187` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (7 lines × 4) · ×1
  • Duplicated block (7 lines × 4) app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:165 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:165-171 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pShareBaseFragment.java:79-85 | app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:224-230 | app/src/main/java/com/solarized/firedown/phone/fragments/StorageReviewFragment.java:180-186 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 4 call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (8 lines × 5) · ×1
  • Duplicated block (8 lines × 5) app/src/main/java/com/solarized/firedown/phone/dialogs/BaseBottomSheetDialogFragment.java:282 — app/src/main/java/com/solarized/firedown/phone/dialogs/BaseBottomSheetDialogFragment.java:282-289 | app/src/main/java/com/solarized/firedown/phone/dialogs/EnrollDialogFragment.java:35-42 | app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:219-226 | app/src/main/java/com/solarized/firedown/settings/BaseFocusFragment.java:47-54 | app/src/main/java/com/solarized/firedown/settings/BasePreferenceFragment.java:104-111 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 5 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (6 lines × 8) · ×1
  • Duplicated block (6 lines × 8) app/src/main/java/com/solarized/firedown/phone/dialogs/SearchEngineSheetDialogFragment.java:195 — app/src/main/java/com/solarized/firedown/phone/dialogs/SearchEngineSheetDialogFragment.java:195-200 | app/src/main/java/com/solarized/firedown/settings/LicenseFragment.java:112-117 | app/src/main/java/com/solarized/firedown/ui/adapters/BrowserTabsAdapter.java:490-495 | app/src/main/java/com/solarized/firedown/ui/adapters/InfoAdapter.java:45-50 | app/src/main/java/com/solarized/firedown/ui/adapters/InfoAdapter.java:80-85 | app/src/main/java/com/solarized/firedown/ui/adapters/SearchAutocompleteAdapter.java:235-240 | app/src/main/java/com/solarized/firedown/ui/adapters/SearchAutocompleteAdapter.java:260-265 | app/src/main/java/com/solarized/firedown/ui/adapters/WebHistoryAdapter.java:253-258 — there are 8 copies across 6 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 8 sites; resolving a subset leaves the remainder to drift apart.
D4 · Code Duplication · Duplicated block (6 lines × 6) · ×1
  • Duplicated block (6 lines × 6) app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:358 — app/src/main/java/com/solarized/firedown/phone/fragments/P2pScanFragment.java:358-363 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pShareBaseFragment.java:245-250 | app/src/main/java/com/solarized/firedown/phone/fragments/P2pShareBaseFragment.java:252-257 | app/src/main/java/com/solarized/firedown/settings/CloudBackupListFragment.java:1722-1727 | app/src/main/java/com/solarized/firedown/settings/CloudDeleteFragment.java:152-157 | app/src/main/java/com/solarized/firedown/settings/SyncSettingsFragment.java:1348-1353 — there are 6 copies across 5 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Note first that the copies are not typed on the same thing: the declarations holding them bind `text` to `CharSequence` in one and `String` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Near-duplicate member pair (46 shared lines) · ×1
  • Near-duplicate member pair (46 shared lines) REDACTED:564 — REDACTED:564-786 | REDACTED:1121-1317 — These two members are variants of one another: 46 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Members sharing a duplicated core (5 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (5 members, 50+ identical tokens) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:360 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:360-407 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:492-514 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:677-717 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:719-747 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:757-791 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
D4 · Code Duplication · Edited copy of a member (37 corresponding lines) · ×1
  • Edited copy of a member (37 corresponding lines) scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:326 — scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:326-364 | REDACTED:465-501 — These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 9+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 9+ corresponding lines) REDACTED:160 — REDACTED:160-169 | REDACTED:176-184 | REDACTED:151-159 | REDACTED:112-120 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (6 members, 12+ corresponding lines) · ×1
  • Edited copies of one member (6 members, 12+ corresponding lines) scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:148 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:148-162 | scripts/engine-harness/src/com/solarized/firedown/harness/EngineStress.java:255-266 | scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:40-52 | scripts/sessions-harness/src/com/solarized/firedown/harness/SessionsHarness.java:131-142 | scripts/thumb-harness/src/com/solarized/firedown/harness/ThumbHarness.java:53-65 | scripts/visit-harness/src/com/solarized/firedown/harness/VisitHarness.java:18-30 — These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (7 members, 4+ corresponding lines) · ×1
  • Edited copies of one member (7 members, 4+ corresponding lines) scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:42 — scripts/engine-harness/src/com/solarized/firedown/harness/EngineHarness.java:42-45 | scripts/engine-harness/src/com/solarized/firedown/harness/EngineStress.java:56-59 | scripts/potoken-harness/src/com/solarized/firedown/geckoview/Harness.java:14-17 | scripts/potoken-harness/src/com/solarized/firedown/geckoview/LeakHarness.java:13-16 | scripts/prompt-harness/src/com/solarized/firedown/harness/PromptHarness.java:25-28 | scripts/sabr-harness/src/com/solarized/firedown/sabr/SabrHarness.java:22-25 | scripts/task-harness/src/com/solarized/firedown/harness/W.java:64-73 — These 7 members are one piece of code written 7 times and then edited apart: every two of them correspond over at least 4 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 7 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 4+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 4+ corresponding lines) scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:16 — scripts/favicon-harness/src/com/solarized/firedown/harness/FaviconHarness.java:16-24 | REDACTED:36-44 | scripts/sessions-harness/src/com/solarized/firedown/harness/SessionsHarness.java:25-33 | scripts/thumb-harness/src/com/solarized/firedown/harness/ThumbHarness.java:29-32 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 4 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (28 lines × 2) · ×1
  • Duplicated block (28 lines × 2) scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:327 — scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:327-354 | REDACTED:466-493 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:327` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `scripts/backup-sim-harness/src/com/solarized/firedown/sync/SimPhone.java:355` calls `synchronized` and `REDACTED:494` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (25 lines × 2) · ×1
  • Duplicated block (25 lines × 2) REDACTED:998 — REDACTED:998-1022 | REDACTED:496-520 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (3–6 lines × 5) · ×1
  • Duplicated block (3–6 lines × 5) scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:377 — scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:377-379 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:502-505 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:690-693 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:731-736 | scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:769-775 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:731` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:689` calls `start` and `scripts/task-harness/src/com/solarized/firedown/harness/TaskHarness.java:731` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (2–5 lines × 4) · ×1
  • Duplicated block (2–5 lines × 4) scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:64 — scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:64-65 | scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:85-89 | scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:106-110 | scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:137-141 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `scripts/sabr-harness/src/com/solarized/firedown/sabr/Fmp4MuxerCases.java:64` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (4–5 lines × 3) · ×1
  • Duplicated block (4–5 lines × 3) REDACTED:1167 — REDACTED:1167-1170 | REDACTED:1175-1179 | REDACTED:1195-1199 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1167` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
P1 · CI/CD gates · No CI pipeline · ×1
  • No CI pipeline — No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, …) — changes aren't gated by an automated build/test.
P2 · Observability · No structured logging · ×1
  • No structured logging — No logging call was found in the 666 JavaScript/TypeScript, JVM production file(s) this check read across 2 module(s). Each was searched for its ecosystem's logging libraries (JVM: SLF4J, Log4j2, java.util.logging, Logback, kotlin-logging, scala-logging; JavaScript/TypeScript: pino, winston, bunyan, log4js, loglevel, consola, the NestJS Logger) and for a call on a receiver named `log`/`logger` (or ending in `Logger`/`_logger`) with a level verb. It cannot see logging through a repo-local wrapper named otherwise, or in source it did not read — this is 'no logging found by this walk', not a verdict that nothing here logs. If it is right, production issues will be hard to diagnose.
R1 · Type Safety · Type Safety · ×1
  • Type Safety — 0 typed · 24 plain JS — the untyped files are REDACTED, scripts/consent-harness.mjs, scripts/consent-smoke.mjs, scripts/dailymotion-replay.mjs, scripts/device-audit/judge.mjs, scripts/device-audit/selftest.mjs (+18 more).
R10 · Code Duplication · Duplicated block (38 lines × 2 locations) · ×1
  • Duplicated block (38 lines × 2 locations) scripts/live-canary.mjs:44 — scripts/live-canary.mjs:44 · REDACTED:20 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication · Duplicated block with local edits (36 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (36 matched lines × 2 locations) scripts/dailymotion-replay.mjs:138 — scripts/dailymotion-replay.mjs:138 · scripts/instagram-replay.mjs:80 — the two spans are one implementation copied and then locally edited — 453 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (30 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (30 matched lines × 2 locations) REDACTED:38 — REDACTED:38 · REDACTED:18 — the two spans are one implementation copied and then locally edited — 266 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (30 lines × 3 locations) · ×1
  • Duplicated block (30 lines × 3 locations) scripts/dailymotion-replay.mjs:34 — scripts/dailymotion-replay.mjs:34 · scripts/live-canary.mjs:44 · REDACTED:20 — the 3 copies are spread across 3 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication · Duplicated block (21 lines × 2 locations) · ×1
  • Duplicated block (21 lines × 2 locations) scripts/live-canary.mjs:102 — scripts/live-canary.mjs:102 · REDACTED:218 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block with local edits (14 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (14 matched lines × 2 locations) scripts/youtube-solver-smoke.mjs:33 — scripts/youtube-solver-smoke.mjs:33 · scripts/youtube-token-smoke.mjs:31 — the two spans are one implementation copied and then locally edited — 234 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (13 lines × 2 locations) · ×1
  • Duplicated block (13 lines × 2 locations) REDACTED:35 — REDACTED:35 · REDACTED:42 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (11 lines × 3 locations) · ×1
  • Duplicated block (11 lines × 3 locations) scripts/har-wire-replay.mjs:155 — scripts/har-wire-replay.mjs:155 · REDACTED:37 · REDACTED:44 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (10 lines × 2 locations) · ×1
  • Duplicated block (10 lines × 2 locations) scripts/consent-harness.mjs:48 — scripts/consent-harness.mjs:48 · scripts/consent-smoke.mjs:26 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block with local edits (10 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (10 matched lines × 2 locations) REDACTED:44 — REDACTED:44 · REDACTED:26 — the two spans are one implementation copied and then locally edited — 51 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (8 lines × 4 locations) · ×1
  • Duplicated block (8 lines × 4 locations) scripts/dailymotion-replay.mjs:258 — scripts/dailymotion-replay.mjs:258 · scripts/dailymotion-replay.mjs:298 · scripts/instagram-replay.mjs:189 · scripts/instagram-replay.mjs:278 — the 4 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (7 lines × 2 locations) · ×1
  • Duplicated block (7 lines × 2 locations) REDACTED:274 — REDACTED:274 · REDACTED:792 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
R10 · Code Duplication · Duplicated block (6 lines × 4 locations) · ×1
  • Duplicated block (6 lines × 4 locations) REDACTED:1049 — REDACTED:1049 · REDACTED:1101 · REDACTED:1647 · REDACTED:2015 — all 4 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (5 lines × 10 locations) · ×1
  • Duplicated block (5 lines × 10 locations) REDACTED:1372 — REDACTED:1372 · REDACTED:1443 · REDACTED:1510 · REDACTED:1520 · +6 more site(s) not listed — all 10 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (5 lines × 4 locations) · ×1
  • Duplicated block (5 lines × 4 locations) REDACTED:808 — REDACTED:808 · REDACTED:982 · REDACTED:1024 · REDACTED:1682 — all 4 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R2 · Cyclomatic Complexity · Complex function judgeSite (cyclomatic 108, cognitive 163) · ×1
  • Complex function judgeSite (cyclomatic 108, cognitive 163) scripts/device-audit/judge.mjs:162 — judgeSite has cyclomatic complexity 108 and cognitive complexity 163; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function formatSite (cyclomatic 29, cognitive 49) · ×1
  • Complex function formatSite (cyclomatic 29, cognitive 49) scripts/device-audit/judge.mjs:360 — formatSite has cyclomatic complexity 29 and cognitive complexity 49; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 27, cognitive 47) · ×1
  • Complex function (anonymous) (cyclomatic 27, cognitive 47) signaling/server.js:146 — (anonymous) has cyclomatic complexity 27 and cognitive complexity 47; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function fetch (cyclomatic 19, cognitive 27) · ×1
  • Complex function fetch (cyclomatic 19, cognitive 27) REDACTED:135 — fetch has cyclomatic complexity 19 and cognitive complexity 27; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function main (cyclomatic 18, cognitive 26) · ×1
  • Complex function main (cyclomatic 18, cognitive 26) scripts/device-audit/judge.mjs:417 — main has cyclomatic complexity 18 and cognitive complexity 26; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function suite (cyclomatic 15, cognitive 11) · ×1
  • Complex function suite (cyclomatic 15, cognitive 11) scripts/youtube-webcompat-smoke.mjs:96 — suite has cyclomatic complexity 15 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function candidateNames (cyclomatic 14, cognitive 24) · ×1
  • Complex function candidateNames (cyclomatic 14, cognitive 24) scripts/device-audit/judge.mjs:133 — candidateNames has cyclomatic complexity 14 and cognitive complexity 24; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function fetch (cyclomatic 11, cognitive 10) · ×1
  • Complex function fetch (cyclomatic 11, cognitive 10) scripts/dailymotion-replay.mjs:106 — fetch has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R4 · Test Coverage · Test Coverage · ×1
  • Test Coverage — 0% of 1 production file(s) reachable from 0 test file(s) via the import graph — 'production' here is the RESIDUE: every source file left once tests, tooling, generated output, config, declarations and declaration-only modules, fixture corpora, type fixtures, behaviour-free data modules, re-export barrels, registration/constant data modules and service workers are set aside, so the percentage is taken over a smaller denominator than the workspace's file count
R7 · Dead Code · Dead file (~284 LoC) · ×1
  • Dead file (~284 LoC) scripts/live-canary.mjs — no import path from any entry point (22 application, 4 tooling, 0 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
X24 · Document value interpolated into markup unescaped · Untrusted text written into markup unescaped · ×1
  • Untrusted text written into markup unescaped signaling/server.js:125 — `id` is text this program did not author, and it is written into a URL attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
Minor — 116 finding(s)
X10 · Duplicated predicate · Duplicated predicate · ×40
  • Duplicated predicate scripts/sabr-harness/src/com/solarized/firedown/sabr/PlayerTokenCases.java:65 — `!demands.isEmpty() && demands.get(0) == call` appears character-identically in 2 files — scripts/sabr-harness/src/com/solarized/firedown/sabr/PlayerTokenCases.java, scripts/sabr-harness/src/com/solarized/firedown/sabr/StreamBindingCases.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java:529 — `!incognito && nightMode != Configuration.UI_MODE_NIGHT_YES` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java, app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate REDACTED:755 — `!segments.isEmpty() && segments.get(segments.size() - 1).isEmpty()` appears character-identically in 2 files — REDACTED, app/src/main/java/com/solarized/firedown/sync/WebDavStore.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/GlideHelper.java:306 — `BuildConfig.DEBUG || BuildConfig.DIAGNOSTIC` appears character-identically in 3 files — app/src/main/java/com/solarized/firedown/GlideHelper.java, app/src/main/java/com/solarized/firedown/manager/HttpDownloadStrategy.java, app/src/main/java/com/solarized/firedown/ui/adapters/BrowserOptionAdapter.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:894 — `FileUriHelper.isImage(mime) || FileUriHelper.isSVG(mime)` appears character-identically in 3 files — app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java, app/src/main/java/com/solarized/firedown/manager/DownloadTask.java, app/src/main/java/com/solarized/firedown/ui/adapters/StorageReviewAdapter.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java:887 — `FileUriHelper.isVideo(mime) || FileUriHelper.isAudio(mime)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/geckoview/GeckoInspectTask.java, app/src/main/java/com/solarized/firedown/ui/adapters/StorageReviewAdapter.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/GlideHelper.java:684 — `FileUriHelper.isVideo(mimeType) || FileUriHelper.isAudio(mimeType)` appears character-identically in 3 files — app/src/main/java/com/solarized/firedown/GlideHelper.java, app/src/main/java/com/solarized/firedown/phone/fragments/BaseFocusFragment.java, app/src/main/java/com/solarized/firedown/ui/adapters/DownloadItemAdapter.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java:1252 — `Lifecycle.Event.ON_PAUSE.equals(event) || Lifecycle.Event.ON_STOP.equals(event)` appears character-identically in 3 files — app/src/main/java/com/solarized/firedown/phone/fragments/BrowserFragment.java, app/src/main/java/com/solarized/firedown/phone/fragments/HomeFragment.java, app/src/main/java/com/solarized/firedown/phone/fragments/HomeIncognitoFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java:386 — `TextUtils.isEmpty(url) || TextUtils.isEmpty(title)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/data/repository/WebBookmarkDataRepository.java, app/src/main/java/com/solarized/firedown/data/repository/WebHistoryDataRepository.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java:110 — `Thread.currentThread().isInterrupted() || isStopped()` appears character-identically in 4 files — app/src/main/java/com/solarized/firedown/manager/tasks/AudioEncodeTask.java, app/src/main/java/com/solarized/firedown/manager/tasks/CompressTask.java, app/src/main/java/com/solarized/firedown/manager/tasks/DecompressTask.java, app/src/main/java/com/solarized/firedown/manager/tasks/GifMakerTask.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java:197 — `action != null && !Boolean.FALSE.equals(action.enabled)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/phone/dialogs/AddonActionsSheetDialogFragment.java, app/src/main/java/com/solarized/firedown/phone/dialogs/SecurityStateSheetDialogFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java:384 — `action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_CANCEL` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/phone/CloudBackupStreamActivity.java, app/src/main/java/com/solarized/firedown/phone/fragments/MediaViewerFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:167 — `actionId == EditorInfo.IME_ACTION_DONE && mConnect.isEnabled()` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java, app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:477 — `active && geckoState.getEntityId() != mCurrentId` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java, app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java:444 — `anchor != null && !TextUtils.isEmpty(label)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/settings/S3ConnectFragment.java, app/src/main/java/com/solarized/firedown/settings/WebDavConnectFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java:128 — `args != null && args.getBoolean(Keys.IS_INCOGNITO, false)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/phone/fragments/WebBookmarkFragment.java, app/src/main/java/com/solarized/firedown/phone/fragments/WebHistoryFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java:274 — `audioCodec != null && !audioCodec.isEmpty()` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegEntity.java, app/src/main/java/com/solarized/firedown/utils/JsonHelper.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java:55 — `blob == null || blob.length < HEADER_LEN` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/sync/crypto/BookmarkBlob.java, app/src/main/java/com/solarized/firedown/sync/crypto/VaultCrypto.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate REDACTED:1505 — `cancelled != null && "cancelled".equals(cancelled.getMessage())` appears character-identically in 2 files — REDACTED, REDACTED. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/donation/DonationPrompt.java:80 — `caps != null && caps.hasCapability(NetworkCapabilities.NET_CAPABILITY_INTERNET)` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/donation/DonationPrompt.java, app/src/main/java/com/solarized/firedown/p2pshare/P2pShareController.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteView.java:416 — `clip == null || clip.getItemCount() == 0` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteView.java, app/src/main/java/com/solarized/firedown/utils/ClipboardHelper.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java:224 — `decodeWidth == originalWidth && decodeHeight == originalHeight` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/glide/FFmpegPfdDecoder.java, app/src/main/java/com/solarized/firedown/glide/FFmpegUriDecoder.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:384 — `geckoState != null && geckoState.getEntityId() == mCurrentId` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java, app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java:620 — `geckoState.isActive() || geckoState.getEntityId() == mCurrentId` appears character-identically in 2 files — app/src/main/java/com/solarized/firedown/data/repository/GeckoStateDataRepository.java, app/src/main/java/com/solarized/firedown/data/repository/IncognitoStateRepository.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate app/src/main/java/com/solarized/firedown/phone/dialogs/BaseBottomSheetDialogFragment.java:260 — `getArguments() != null && getArguments().getBoolean(Keys.IS_INCOGNITO, false)` appears character-identically in 3 files — app/src/main/java/com/solarized/firedown/phone/dialogs/BaseBottomSheetDialogFragment.java, app/src/main/java/com/solarized/firedown/phone/dialogs/BaseDialogFragment.java, app/src/main/java/com/solarized/firedown/phone/dialogs/BrowserOptionFragment.java. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • + 15 more in this group — see findings.md.
X7 · Silent fallback defaults · Silent fallback default in catch · ×24
  • Silent fallback default in catch REDACTED:673 — `parseAmzDate` swallows every exception into `return 0` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/java/com/solarized/firedown/data/entity/CertificateInfoEntity.java:404 — `parseSANs` swallows every exception into `return Collections.emptyList()` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:215 — `externalizeToDir` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:241 — `readFromFile` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:131 — `externalizeToDir` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:1033 — `pageKeyTail` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:1215 — `parseHttpDate` swallows every exception into `return 0` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:1203 — `parseIso` swallows every exception into `return 0` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch REDACTED:746 — `parseHttpDate` swallows every exception into `return 0` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/java/com/solarized/firedown/ui/adapters/MostVisitedTilesAdapter.java:115 — `siteLabel` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:140 — `extractBrand` swallows every exception into `return "unknown"` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/java/com/solarized/firedown/utils/FiredownNameHelper.java:174 — `extractExtension` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it propagate. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/blocked-stats.js:56 — `hostOf` swallows every exception into `return ''` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/content-script.js:3487 — `manifestSourceOf` swallows every exception into `return ''` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/page-state-bridge.js:491 — `findPlayerMedia` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/page-state-bridge.js:602 — `mediaFileKey` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/page-state-bridge.js:1478 — `fetchMediaList` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/page-state-bridge.js:1722 — `mediaElementCount` swallows every exception into `return 0` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/requests.js:364 — `resolveTabId` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/requests.js:2093 — `vttVerdictFor` swallows every exception into `return 'unknown'` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/webrequests/js/parsers/tiktok.js:31 — `browser.webRequest.onBeforeRequest.addListener()` swallows every exception into `return {}` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/youtube/background.js:2198 — `visitorIdOf` (in `processVideo`) swallows every exception into `return "?"` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch app/src/main/assets/youtube/background.js:2770 — `streamIdOf` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch scripts/device-audit/judge.mjs:68 — `hostOf` swallows every exception into `return ""` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
X7 · Silent fallback defaults · Silent fallback default on parse failure · ×14
  • Silent fallback default on parse failure REDACTED:594 — `contentLength` returns `-1` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/data/repository/BrowserDownloadRepository.java:469 — `imagePixels` returns `0L` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegOkhttp.java:604 — `parseTotalFromContentRange` returns `-1` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegUtils.java:35 — `compare` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/ffmpegutils/FFmpegUtils.java:67 — `sampleRateHz` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/manager/SabrStrategy.java:674 — `parseLongSafe` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/phone/fragments/StorageFragment.java:344 — `freeBytes` returns `-1` when `IllegalArgumentException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure REDACTED:1191 — `parseLong` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure REDACTED:1236 — `rangeStart` returns `-1` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure REDACTED:737 — `parseLong` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure REDACTED:782 — `rangeStart` returns `-1` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:331 — `parseIntSafe` returns `0` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/utils/M3U8Parser.java:339 — `parseLongSafe` returns `0L` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
  • Silent fallback default on parse failure app/src/main/java/com/solarized/firedown/AppLock.java:64 — `getPreferencesTime` returns `0L` when `NumberFormatException` is thrown, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment in the catch or in the Javadoc, and the row stops firing.
X6 · Hand-rolled structured-format parsing · Hand-rolled JSON/XML parsing via regex · ×9
  • Hand-rolled JSON/XML parsing via regex app/src/main/java/com/solarized/firedown/utils/BookmarkHtml.java:45 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JVM code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:114 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:990 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:1013 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:2181 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:2215 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:2216 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/youtube/background.js:2356 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
  • Hand-rolled JSON/XML parsing via regex app/src/main/assets/webrequests/js/parsers/acast.js:81 — A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand — malformed or differently-typed content (e.g. `"amount": "5"` as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too.
AX6 · Interface segregation · Fat interface · ×7
  • Fat interface: Phone (18 abstract methods) scripts/backup-sim-harness/src/simapi/Phone.java:16 — `Phone` declares 18 abstract methods under just 15 distinct name(s): `account`, `backup`, `cancelBackups`, `delete`, `delete`, `deleteAll`, `describe`, `list`, `name`, `open`, `open`, `restore`, `restore`, `setClockOffset`, `setCode`, `sweepUploadsNow`, `useDav`, `useS3`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. That is an OVERLOAD SET, not 18 separate responsibilities: a caller binds to 15 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 18 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface.
  • Fat interface: DownloadDao (36 abstract methods) app/src/main/java/com/solarized/firedown/data/dao/DownloadDao.java:18 — `DownloadDao` declares 36 abstract methods: `deleteAll`, `deleteSync`, `deleteSyncEntities`, `deleteSyncEntity`, `findByFilePath`, `findById`, `findByIdSync`, `findByNameSize`, `findPlayerCompanions`, `getAllIds`, `getAllRaw`, `getAllRawEnc`, `getAllRawList`, `getAllRegularLive`, `getAllSafeLive`, `getCaptureStatesLive`, `getDownloads`, `getDownloadsDomain`, `getDownloadsName`, `getDownloadsSize`, `getRegularFinishedCount`, `getRegularFinishedSizeLive`, `getRegularFinishedSync`, `getRegularUsageByMimeLive`, `getRowCount`, `getSafe`, `getSafeDomain`, `getSafeName`, `getSafeRowCountLive`, `getSafeSize`, `insert`, `insertAll`, `insertSync`, `search`, `setParentId`, `setThumbnailUnavailableSync`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: WebBookmarkDao (20 abstract methods) app/src/main/java/com/solarized/firedown/data/dao/WebBookmarkDao.java:17 — `WebBookmarkDao` declares 20 abstract methods: `delete`, `deleteAll`, `deleteById`, `gcTombstones`, `getAllForSync`, `getAllIds`, `getAllRaw`, `getAutoCompleteSearch`, `getBookmark`, `getBookmarks`, `getBookmarksAlphabetical`, `getId`, `getRowCount`, `insert`, `insertAll`, `search`, `softDelete`, `softDeleteAll`, `updateIcon`, `updateTitleIfPlaceholder`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: WebHistoryDao (18 abstract methods) app/src/main/java/com/solarized/firedown/data/dao/WebHistoryDao.java:20 — `WebHistoryDao` declares 18 abstract methods: `delete`, `deleteAll`, `deleteById`, `deleteRange`, `getAutoCompleteFts`, `getAutoCompleteHistory`, `getAutoCompleteSearch`, `getHistory`, `getHistory`, `getHistorySync`, `getLatestWithIcon`, `getMostVisited`, `getRowCount`, `getSearch`, `insert`, `purgeDatabase`, `updateIcon`, `updateTitleByUrl`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. Those 18 declarations carry 17 distinct name(s), so part of the width is overloading rather than separate responsibilities — but 17 operations clears the >15 bar on its own, so the row is about responsibilities, not signatures. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: Download (25 abstract methods) app/src/main/java/com/solarized/firedown/data/Download.java:3 — `Download` declares 25 abstract methods: `getDuration`, `getDurationFormatted`, `getFileDate`, `getFileDescription`, `getFileErrorType`, `getFileHeaders`, `getFileImg`, `getFileIsLive`, `getFileLanguage`, `getFileMimeType`, `getFileName`, `getFilePath`, `getFileProgress`, `getFileResolution`, `getFileSize`, `getFileStatus`, `getFileType`, `getFileUrl`, `getId`, `getOriginUrl`, `getParentId`, `getThumbnailDuration`, `isFileEncrypted`, `isFileSafe`, `isFileThumbnailUnavailable`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: TabState (19 abstract methods) app/src/main/java/com/solarized/firedown/data/TabState.java:6 — `TabState` declares 19 abstract methods: `canGoBackward`, `canGoForward`, `getCertificateState`, `getCreationDate`, `getIcon`, `getId`, `getParentId`, `getPreview`, `getSessionState`, `getTabId`, `getTitle`, `getUri`, `isActive`, `isDesktop`, `isFirstContentFulPaint`, `isFullScreen`, `isHome`, `isIncognito`, `isSearchMode`. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: GeckoObserver (44 abstract methods) app/src/main/java/com/solarized/firedown/geckoview/GeckoObserver.java:13 — `GeckoObserver` declares 44 abstract methods: `onClose`, `onContentPermission`, `onContext`, `onCrash`, `onDownload`, `onDrmDisabled`, `onFirstComposite`, `onFullScreen`, `onHideBars`, `onKill`, `onLoadRequest`, `onLocationChange`, `onMediaActivated`, `onMediaDeactivated`, `onMediaMetadata`, `onMediaPause`, `onMediaPlay`, `onMediaPosition`, `onMediaRefused`, `onMediaStop`, `onMetaViewportFitChange`, `onNew`, `onOrientation`, `onPointerIconChange`, `onPromptAlert`, `onPromptAuth`, `onPromptButton`, `onPromptChoice`, `onPromptColor`, `onPromptDate`, `onPromptFile`, `onPromptRepost`, `onPromptShare`, `onPromptText`, `onPromptUnload`, `onScrollChange`, `onSecurityChange`, `onShowDynamicToolbar`, `onStart`, `onStop`, and 4 more. Counted over its ABSTRACT methods, once per signature; `default`, `static` and `private` methods and constants are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
D26 · Project Cohesion · Projects may be oversized for their cohesion · ×2
  • Projects may be oversized for their cohesion app/build.gradle:1 — `app` (172738 LoC, 832 module-visible types across 50 directories) overshoots its size bounds. 2 of 2 build unit(s) (Gradle) overshoot their size bounds, lowering Project Cohesion to 0.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion build.gradle:1 — `(repository root)` (37506 LoC, 83 module-visible types across 38 directories) overshoots its size bounds. 2 of 2 build unit(s) (Gradle) overshoot their size bounds, lowering Project Cohesion to 0.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
D29 · Static Analysis (SAST) · REDACTED · ×2
  • REDACTED
  • REDACTED
IC1 · Incompleteness & stubs · Blanket warning suppression · ×2
  • Blanket warning suppression app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:89 — `@SuppressWarnings("all")` switches every compiler and analyser warning off for the whole declaration — hidden debt. Suppress the specific warning on the specific member, with a justification, instead.
  • Blanket warning suppression app/src/main/java/com/solarized/firedown/ui/CardViewListItemDecoration.java:103 — `@SuppressWarnings("all")` switches every compiler and analyser warning off for the whole declaration — hidden debt. Suppress the specific warning on the specific member, with a justification, instead.
D20 · ADR Quality · No ADRs found · ×1
  • No ADRs found app/build.gradle:2 — No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in `docs/adr/`. ADRs are expected here because `app/build.gradle` makes this repository a deployable product (line 2).
D21 · Naming Consistency · `getDRMEnabled` spells `DRM` where 20 names in the project spell it `Drm` · ×1
  • `getDRMEnabled` spells `DRM` where 20 names in the project spell it `Drm` app/src/main/java/com/solarized/firedown/Preferences.java:929 — 20 of 22 names in project app spell the token `Drm` (20 of 22; unit: names in project app containing `Drm`). Peers: PermissionDelegate.onDrmRequest (app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1797); GeckoObserver.onDrmDisabled (app/src/main/java/com/solarized/firedown/geckoview/GeckoObserver.java:147); GeckoState.claimDrmNotice (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:750); GeckoState.resetDrmNotice (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:786); GeckoState.markDrmGranted (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:792). Rename to `getDrmEnabled`. [rule N6]
D21 · Naming Consistency · `BrowserURIViewModel` spells `URI` where 70 names in the project spell it `Uri` · ×1
  • `BrowserURIViewModel` spells `URI` where 70 names in the project spell it `Uri` app/src/main/java/com/solarized/firedown/data/models/BrowserURIViewModel.java:28 — 70 of 71 names in project app spell the token `Uri` (70 of 71; unit: names in project app containing `Uri`). Peers: IntentHandler.handleExternalUri (app/src/main/java/com/solarized/firedown/IntentHandler.java:187); IntentHandler.handleOpenUri (app/src/main/java/com/solarized/firedown/IntentHandler.java:214); Preferences.getDohUri (app/src/main/java/com/solarized/firedown/Preferences.java:874); AddonManager.installFromUri (app/src/main/java/com/solarized/firedown/addons/AddonManager.java:966); DownloadBackupMirror.rememberRestoreTree(treeUri) (app/src/main/java/com/solarized/firedown/data/DownloadBackupMirror.java:322). Rename to `BrowserUriViewModel`. [rule N6]
D21 · Naming Consistency · `setDRM` spells `DRM` where 20 names in the project spell it `Drm` · ×1
  • `setDRM` spells `DRM` where 20 names in the project spell it `Drm` app/src/main/java/com/solarized/firedown/geckoview/GeckoRuntimeHelper.java:1491 — 20 of 22 names in project app spell the token `Drm` (20 of 22; unit: names in project app containing `Drm`). Peers: PermissionDelegate.onDrmRequest (app/src/main/java/com/solarized/firedown/geckoview/GeckoComponents.java:1797); GeckoObserver.onDrmDisabled (app/src/main/java/com/solarized/firedown/geckoview/GeckoObserver.java:147); GeckoState.claimDrmNotice (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:750); GeckoState.resetDrmNotice (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:786); GeckoState.markDrmGranted (app/src/main/java/com/solarized/firedown/geckoview/GeckoState.java:792). Rename to `setDrm`. [rule N6]
D21 · Naming Consistency · `NotificationID` spells `ID` where 424 names in the project spell it `Id` · ×1
  • `NotificationID` spells `ID` where 424 names in the project spell it `Id` app/src/main/java/com/solarized/firedown/utils/NotificationID.java:5 — 424 of 426 names in project app spell the token `Id` (424 of 426; unit: names in project app containing `Id`). Peers: BaseActivity.showsDestination(destinationId) (app/src/main/java/com/solarized/firedown/BaseActivity.java:559); BaseActivity.startDownload(anchorId) (app/src/main/java/com/solarized/firedown/BaseActivity.java:778); Sorting.setCurrentSortDownloadsForId (app/src/main/java/com/solarized/firedown/Sorting.java:48); Sorting.setCurrentSortDownloadsForId(selectedId) (app/src/main/java/com/solarized/firedown/Sorting.java:48); Sorting.getCurrentSortForIds(selectedId) (app/src/main/java/com/solarized/firedown/Sorting.java:52). Rename to `NotificationId`. [rule N6]
D21 · Naming Consistency · `getID` spells `ID` where 424 names in the project spell it `Id` · ×1
  • `getID` spells `ID` where 424 names in the project spell it `Id` app/src/main/java/com/solarized/firedown/utils/NotificationID.java:52 — 424 of 426 names in project app spell the token `Id` (424 of 426; unit: names in project app containing `Id`). Peers: BaseActivity.showsDestination(destinationId) (app/src/main/java/com/solarized/firedown/BaseActivity.java:559); BaseActivity.startDownload(anchorId) (app/src/main/java/com/solarized/firedown/BaseActivity.java:778); Sorting.setCurrentSortDownloadsForId (app/src/main/java/com/solarized/firedown/Sorting.java:48); Sorting.setCurrentSortDownloadsForId(selectedId) (app/src/main/java/com/solarized/firedown/Sorting.java:48); Sorting.getCurrentSortForIds(selectedId) (app/src/main/java/com/solarized/firedown/Sorting.java:52). Rename to `getId`. [rule N6]
D21 · Naming Consistency · `AssetJSONFile` spells `JSON` where 14 names in the project spell it `Json` · ×1
  • `AssetJSONFile` spells `JSON` where 14 names in the project spell it `Json` app/src/main/java/com/solarized/firedown/utils/Utils.java:650 — 14 of 15 names in project app spell the token `Json` (14 of 15; unit: names in project app containing `Json`). Peers: UpdatePlan.toJson (app/src/main/java/com/solarized/firedown/UpdatePlan.java:139); UpdatePlan.fromJson (app/src/main/java/com/solarized/firedown/UpdatePlan.java:165); UpdateWorker.fetchStatusJson (app/src/main/java/com/solarized/firedown/UpdateWorker.java:158); AutoCompleteSearch.processJsonArray (app/src/main/java/com/solarized/firedown/autocomplete/AutoCompleteSearch.java:438); CrashReport.toJson (app/src/main/java/com/solarized/firedown/crash/CrashReport.java:96). Rename to `AssetJsonFile`. [rule N6]
D28 · Secrets (history) · Rotate the exposed credentials · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
M2 · Architecture documentation · No ADRs · ×1
  • No ADRs — No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
M2 · Architecture documentation · No architecture diagram/doc · ×1
  • No architecture diagram/doc — No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named `architecture` or `design` in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape — no `## Architecture` heading, no "architecture overview"/"high-level design" phrasing, no "the architecture is …" introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document — not evidence that nobody wrote the shape down.
P3 · Security & performance tooling · No SAST · ×1
  • No SAST — No static application security testing detected. For this repository's stack, add spotbugs with find-sec-bugs (or `semgrep --config=auto`, which runs on any language) — this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
P3 · Security & performance tooling · No dependency-update automation · ×1
  • No dependency-update automation build.gradle:8 — `build.gradle` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`.
R7 · Dead Code · Unused module-local declaration 'AUDIO_RE' · ×1
  • Unused module-local declaration 'AUDIO_RE' scripts/device-audit/judge.mjs:38 — This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
X2 · Cancellation propagation · Not all async functions that make a request accept an AbortSignal · ×1
  • Not all async functions that make a request accept an AbortSignal — Only 10/23 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
X5 · Nullable reference types · Java packages are not null-marked everywhere · ×1
  • Java packages are not null-marked everywhere — 0/45 of this repository's Java package directories are under a non-null default: a `package-info.java` declaring `@NullMarked` (JSpecify) or `@NonNullApi`, `@ParametersAreNonnullByDefault`, `@NonNullByDefault`, `@DefaultQualifier(NonNull.class)`; a `module-info.java` declaring `@NullMarked`; every type in it `@NullMarked`; or a build that runs NullAway with the package in `AnnotatedPackages`, or the Checker Framework's `NullnessChecker`. Elsewhere every reference admits null and no checker warns on the dereference that throws a `NullPointerException`.

Appendix B — Reproduction & audit trail

Every external tool invocation behind a deep-scan dimension — the tool, its captured version, the exact command, how many findings it yielded, and a link to the retained raw output. To reproduce any finding: check out the same commit and run the command shown (repo-relative — never an absolute scratch path). The complete raw scanner output is retained verbatim under artifacts/raw/ (indexed in artifacts/raw/index.json); per-invocation exit codes and wall-clock durations are in sidecar.json — kept out of this table so the rendered report stays byte-identical across runs of the same commit.

DimensionToolVersionCommandFindingsRaw output
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=0 --max-count=200" --report-format json --report-path /tmp/watchdog-gitleaks-37af6a231df6466d8d155ac0f44f7e14/history.json --exit-code 0 --source .0artifacts/raw/gitleaks-history.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=200 --max-count=800" --report-format json --report-path /tmp/watchdog-gitleaks-37af6a231df6466d8d155ac0f44f7e14/history-1.json --exit-code 0 --source .1artifacts/raw/gitleaks-history-1.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=1000 --max-count=2218" --report-format json --report-path /tmp/watchdog-gitleaks-37af6a231df6466d8d155ac0f44f7e14/history-2.json --exit-code 0 --source .3artifacts/raw/gitleaks-history-2.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-37af6a231df6466d8d155ac0f44f7e14/tree.json --exit-code 0 --source .3artifacts/raw/gitleaks-tree.json
D29 · Static Analysis (SAST)semgrep—semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/canine-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off --exclude *.arrow --exclude *.avro --exclude *.csv --exclude *.dat --exclude *.db --exclude *.feather --exclude *.geojson --exclude *.h5 --exclude *.hdf5 --exclude *.jsonl --exclude *.log --exclude *.ndjson --exclude *.npy --exclude *.npz --exclude *.orc --exclude *.parquet --exclude *.pickle --exclude *.pkl --exclude *.psv --exclude *.sqlite --exclude *.sqlite3 --exclude *.tfrecord --exclude *.tsv --exclude *.txt .69artifacts/raw/semgrep.json
D30 · Dependency Vulnerabilitiesnone (dependency manifest found, not scanned for vulnerabilities here)—none (dependency manifest found, not scanned for vulnerabilities here): not applicable — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Gradle build (build.gradle/build.gradle.kts) — not scanned yet).0—
D31 · IaC & Container Securitytrivy—trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.0—
D32 · Data Compliance (PII/GDPR)semgrep—semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. semgrep could not parse 1 file(s) — `app/src/main/assets/webrequests/js/snapshot.js` — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.0—
D36 · Supply-chain Provenance & Signingprovenance—provenance: not applicable — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for.0—
D40 · Network Egress Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.0—
D41 · Kernel & Syscall Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.0—
D42 · Runtime Threat Enforcementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.0—
D43 · Malicious Dependenciesnone (dependency manifest found, not scanned for vulnerabilities here)—none (dependency manifest found, not scanned for vulnerabilities here): not applicable — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Gradle build (build.gradle/build.gradle.kts) — not scanned yet).0—

Run 01a1e7ce-f2cb-7cc6-a5d6-e9fd5ef3b4f7 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.

Downloadable artifacts

Machine-readable and reproducible from this commit + frozen rubric — drop them straight into a contract appendix, a CRA dossier, or a downstream SCA / VEX tool.

⬇ Findings, MITRE CWE-tagged .sarif⬇ Health changelog .md