updated package file and added package function