adjust to different exception in PHP 8
adjust to different exception in PHP 8

Once PHP 8 is required this test can be dropped though, as a union
type hint can be added to NewInstance::of().

mikey179/bovigo-callmap