cleaner return logic in get package state