(source, localImportMap, gate = 'always')
| 564 | } |
| 565 | |
| 566 | function parseRegistrationCalls(source, localImportMap, gate = 'always') { |
| 567 | const rows = [] |
| 568 | for (const match of source.matchAll(/\b(register[A-Za-z_$][\w$]*)\(\)/g)) { |
| 569 | const symbol = match[1] |
| 570 | if (symbol === 'registerBundledSkill' || symbol === 'registerBuiltinPlugin') continue |
| 571 | const specifier = localImportMap.get(symbol) |
| 572 | if (!specifier) continue |
| 573 | rows.push({ symbol, specifier, gate }) |
| 574 | } |
| 575 | return rows |
| 576 | } |
| 577 | |
| 578 | function resolveGate(entry, importInfo) { |
| 579 | const rawGate = entry.gate || importInfo?.gate || 'always' |
no test coverage detected