Commit 3229447
committed
fix(core): compose nested withAuth by merging from enclosing scope
`runWithConfig` was building its merged config from the process-wide
global, not from the enclosing ALS scope. That broke the documented
`auth.withAuth(...)` + `auth.withPublicToken(...)` composition: the
inner `withAuth` (called by withPublicToken internally) silently
dropped the outer scope's baseURL/branch overrides.
Read from the active scope first, fall back to the global, then merge
in the new config. Pre-existing concurrency-safety (parallel scopes)
holds. New test covers the nested-composition case.1 parent 5968d6a commit 3229447
2 files changed
Lines changed: 18 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
123 | | - | |
| 123 | + | |
| 124 | + | |
124 | 125 | | |
125 | 126 | | |
126 | 127 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
244 | 260 | | |
245 | 261 | | |
246 | 262 | | |
| |||
0 commit comments