fixed isPackageAvailable