Skip to content

Commit a5300a4

Browse files
Fix validation for _global APIs (#4659) (#4660)
The existing namespace computation was too naive. (cherry picked from commit bd228bb) Co-authored-by: Quentin Pradet <[email protected]>
1 parent b2dc43c commit a5300a4

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

.github/validate-pr/index.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ async function run() {
105105
ci: false,
106106
verbose: false
107107
})
108-
const [namespace, _method] = api.split('.')
108+
const namespace = getNamespace(api)
109109
// Asked to validate a specific API, so we only store that one
110110
reports.set(api, report.get(namespace)[0])
111111
}
@@ -120,7 +120,7 @@ async function run() {
120120
verbose: false
121121
})
122122

123-
const [namespace, _method] = api.split('.')
123+
const namespace = getNamespace(api)
124124
// Asked to validate a specific API, so we only store that one
125125
reports.set(api, report.get(namespace)[0])
126126
}
@@ -162,7 +162,6 @@ function getApi (file) {
162162
return file.split('/').slice(1, 3).filter(s => !privateNames.includes(s)).filter(Boolean).join('.')
163163
}
164164

165-
166165
function findBaselineReport(apiName, baselineValidation) {
167166
const [namespace, method] = apiName.split('.')
168167

0 commit comments

Comments
 (0)