Commit 2a00c7c
committed
fix(proxy): remove dead email fallback and add fetch timeout in token identity resolver
GitHub's GET /user only returns email if the user has explicitly made it
public — effectively never. Remove the if (identity.email) branch and
the email field from ScmUserInfo to avoid the misleading implication
that an email fallback exists.
Add AbortSignal.timeout(5000) to the GitHub API fetch to prevent the
push chain from hanging if the API is slow or unreachable.1 parent 640ad1c commit 2a00c7c
3 files changed
Lines changed: 12 additions & 29 deletions
File tree
- src/proxy/processors/push-action
- test/processors
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
91 | | - | |
92 | | - | |
93 | | - | |
| 91 | + | |
94 | 92 | | |
95 | 93 | | |
96 | 94 | | |
| |||
107 | 105 | | |
108 | 106 | | |
109 | 107 | | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | 108 | | |
114 | 109 | | |
115 | 110 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
| |||
68 | 67 | | |
69 | 68 | | |
70 | 69 | | |
71 | | - | |
72 | | - | |
73 | 70 | | |
74 | 71 | | |
75 | 72 | | |
| |||
86 | 83 | | |
87 | 84 | | |
88 | 85 | | |
| 86 | + | |
89 | 87 | | |
90 | 88 | | |
91 | 89 | | |
| |||
98 | 96 | | |
99 | 97 | | |
100 | 98 | | |
101 | | - | |
102 | 99 | | |
103 | 100 | | |
104 | 101 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
72 | | - | |
| 72 | + | |
73 | 73 | | |
74 | 74 | | |
75 | | - | |
| 75 | + | |
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
86 | 87 | | |
87 | 88 | | |
88 | 89 | | |
89 | | - | |
90 | | - | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | 90 | | |
101 | 91 | | |
102 | 92 | | |
| |||
214 | 204 | | |
215 | 205 | | |
216 | 206 | | |
217 | | - | |
| 207 | + | |
218 | 208 | | |
219 | 209 | | |
220 | 210 | | |
| |||
223 | 213 | | |
224 | 214 | | |
225 | 215 | | |
226 | | - | |
| 216 | + | |
227 | 217 | | |
228 | 218 | | |
229 | 219 | | |
230 | 220 | | |
231 | 221 | | |
| 222 | + | |
232 | 223 | | |
233 | 224 | | |
234 | 225 | | |
| |||
247 | 238 | | |
248 | 239 | | |
249 | 240 | | |
250 | | - | |
| 241 | + | |
251 | 242 | | |
252 | 243 | | |
253 | 244 | | |
| |||
259 | 250 | | |
260 | 251 | | |
261 | 252 | | |
262 | | - | |
| 253 | + | |
263 | 254 | | |
264 | 255 | | |
265 | | - | |
| 256 | + | |
266 | 257 | | |
267 | 258 | | |
268 | 259 | | |
| |||
0 commit comments