Disallow and suppress unsafe assignment (#19736)

This commit is contained in:
Christian Gunderman
2026-02-20 22:28:55 +00:00
committed by GitHub
parent b746524a1b
commit 58d637f919
71 changed files with 149 additions and 22 deletions
+2
View File
@@ -88,6 +88,7 @@ export function createWorkingStdio() {
if (prop === 'write') {
return writeToStdout;
}
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
const value = Reflect.get(target, prop, receiver);
if (typeof value === 'function') {
return value.bind(target);
@@ -101,6 +102,7 @@ export function createWorkingStdio() {
if (prop === 'write') {
return writeToStderr;
}
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
const value = Reflect.get(target, prop, receiver);
if (typeof value === 'function') {
return value.bind(target);