Skip to content

Commit

Permalink
Updated with array key type
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrejmirtes committed Nov 22, 2017
1 parent fd44abf commit 84dd833
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
use PHPStan\Analyser\Scope;
use PHPStan\Reflection\MethodReflection;
use PHPStan\Type\ArrayType;
use PHPStan\Type\IntegerType;
use PHPStan\Type\MixedType;
use PHPStan\Type\ObjectType;
use PHPStan\Type\Type;
Expand Down Expand Up @@ -45,7 +46,7 @@ public function getTypeFromMethodCall(
return TypeCombinator::addNull($entityType);
}

return new ArrayType($entityType);
return new ArrayType(new IntegerType(), $entityType);
}

}

0 comments on commit 84dd833

Please # to comment.