isinstance fixes