fix issue with packageVersions being undefined