simpler isFunction