fix package read bug introduced by last commit