From 04052375b170b6c993201b52b288867dc77d0665 Mon Sep 17 00:00:00 2001 From: Marco Wang Date: Wed, 27 May 2026 14:48:08 -0700 Subject: [PATCH] manually fix a few more files (#1719) Summary: X-link: https://github.com/facebook/react-native/pull/56983 X-link: https://github.com/facebook/relay/pull/5300 skipped by codemod. Fixing them manually Reviewed By: gkz Differential Revision: D106557702 --- private/metro-memory-fs/src/index.js | 32 ++++++++++++++-------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/private/metro-memory-fs/src/index.js b/private/metro-memory-fs/src/index.js index 101f656791..620a0948cc 100644 --- a/private/metro-memory-fs/src/index.js +++ b/private/metro-memory-fs/src/index.js @@ -64,19 +64,19 @@ type Encoding = | 'utf8'; type Resolution = { - +basename: string, - +dirNode: DirectoryNode, - +dirPath: Array<[string, EntityNode]>, - +drive: string, - +node: ?EntityNode, - +realpath: string, + readonly basename: string, + readonly dirNode: DirectoryNode, + readonly dirPath: Array<[string, EntityNode]>, + readonly drive: string, + readonly node: ?EntityNode, + readonly realpath: string, }; type Descriptor = { - +nodePath: Array<[string, EntityNode]>, - +node: FileNode, - +readable: boolean, - +writable: boolean, + readonly nodePath: Array<[string, EntityNode]>, + readonly node: FileNode, + readonly readable: boolean, + readonly writable: boolean, position: number, }; @@ -1272,8 +1272,8 @@ class MemoryFs { } _parsePath(filePath: string): { - +drive: ?string, - +entNames: Array, + readonly drive: ?string, + readonly entNames: Array, } { let drive; const sep = this._platform === 'win32' ? /[\\/]/ : /\//; @@ -1297,8 +1297,8 @@ class MemoryFs { } _parsePathWithCwd(filePath: string): { - +drive: string, - +entNames: Array, + readonly drive: string, + readonly entNames: Array, } { let {drive, entNames} = this._parsePath(filePath); if (drive == null) { @@ -1744,8 +1744,8 @@ class FSWatcher extends EventEmitter { } class Dirent { - +_stats: Stats; - +name: string | Buffer; + readonly _stats: Stats; + readonly name: string | Buffer; /** * Don't keep a reference to the node as it may get mutated over time.