Commit a794452
committed
fix(auth): skip auth-alternative-access when auth-gate-detection fails from fetch errors
When all pages fail to fetch (DNS NXDOMAIN, network error, etc.),
auth-gate-detection returns 'fail' with details containing fetchErrors
but no gated/accessible counts. auth-alternative-access then computed
gatedCount=0 and falsely reported "no alternative access paths,"
triggering the auth-no-alternative critical diagnostic for sites that
were simply unreachable rather than auth-gated.
Skip auth-alternative-access when gatedCount === 0 && fetchErrors > 0.
This combination uniquely identifies the network-error case, since
every other non-pass path through auth-gate-detection produces
gatedCount > 0. The no-viable-path diagnostic continues to fire
correctly for unreachable sites since it is driven by separate signals.
Fixes #851 parent 0627325 commit a794452
2 files changed
Lines changed: 40 additions & 0 deletions
File tree
- src/checks/authentication
- test/unit/checks
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
| |||
59 | 60 | | |
60 | 61 | | |
61 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
62 | 77 | | |
63 | 78 | | |
64 | 79 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
71 | 71 | | |
72 | 72 | | |
73 | 73 | | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
74 | 99 | | |
75 | 100 | | |
76 | 101 | | |
| |||
0 commit comments