Implemented package type logic