use instanceof when checking instances in does_role