Disallow underspecified types (#21485)

This commit is contained in:
Christian Gunderman
2026-03-07 21:05:38 +00:00
committed by GitHub
parent 245b68e9f1
commit dac3735626
18 changed files with 51 additions and 7 deletions
+2
View File
@@ -63,6 +63,7 @@ function getStringReferences(parts: AnyPart[]): StringReference[] {
});
}
} else if (part instanceof GenericPart) {
// eslint-disable-next-line no-restricted-syntax
if (part.type === 'executableCode' && typeof part['code'] === 'string') {
refs.push({
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
@@ -73,6 +74,7 @@ function getStringReferences(parts: AnyPart[]): StringReference[] {
});
} else if (
part.type === 'codeExecutionResult' &&
// eslint-disable-next-line no-restricted-syntax
typeof part['output'] === 'string'
) {
refs.push({