Revert to isinstance for nhist test.