Skip to content
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.

fix #109 pkg no times and no versions bug. #110

Merged
merged 1 commit into from
Dec 19, 2013
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions proxy/sync_module_worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,10 +182,14 @@ SyncModuleWorker.prototype._sync = function (pkg, callback) {
var missingDescriptions = [];
ep.all('existsMap', 'existsTags', function (map, tags) {
var times = pkg.time || {};
pkg.versions = pkg.versions || {};
var versionNames = Object.keys(times);
if (versionNames.length === 0) {
versionNames = Object.keys(pkg.versions);
}
if (versionNames.length === 0) {
that.log(' [%s] no times and no versions', pkg.name);
}
var versions = [];
for (var i = 0; i < versionNames.length; i++) {
var v = versionNames[i];
Expand Down