Simplify expression in resolveObjectIntersection

This commit is contained in:
Nathan Shively-Sanders 2016-10-21 13:38:24 -07:00
parent 422f73b1a9
commit fdfb159024

View File

@ -5924,7 +5924,7 @@ namespace ts {
}
function resolveObjectIntersection(intersection: IntersectionType): IntersectionType | ResolvedType {
if (find(intersection.types, t => !(t.flags & TypeFlags.ObjectType && !couldContainTypeParameters(t)))) {
if (find(intersection.types, t => !(t.flags & TypeFlags.ObjectType) || couldContainTypeParameters(t))) {
return intersection;
}
const properties = getPropertiesOfType(intersection);