Fixing Scrutinizer issue, where objects are not considered as a subtype of null.