File tree 1 file changed +5
-2
lines changed 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -12219,8 +12219,11 @@ namespace ts {
12219
12219
}
12220
12220
12221
12221
function isMappedTypeGenericIndexedAccess(type: Type) {
12222
- return type.flags & TypeFlags.IndexedAccess && getObjectFlags((type as IndexedAccessType).objectType) & ObjectFlags.Mapped &&
12223
- !isGenericMappedType((type as IndexedAccessType).objectType) && isGenericIndexType((type as IndexedAccessType).indexType);
12222
+ let objectType;
12223
+ return !!(type.flags & TypeFlags.IndexedAccess && getObjectFlags(objectType = (type as IndexedAccessType).objectType) & ObjectFlags.Mapped &&
12224
+ !isGenericMappedType(objectType) && isGenericIndexType((type as IndexedAccessType).indexType) &&
12225
+ !(getMappedTypeModifiers(objectType as MappedType) & (MappedTypeModifiers.IncludeOptional | MappedTypeModifiers.ExcludeOptional)) &&
12226
+ !(getNameTypeFromMappedType(objectType as MappedType)));
12224
12227
}
12225
12228
12226
12229
/**
You can’t perform that action at this time.
0 commit comments