Use command -v rather than type