Comparing version 0.0.2 to 0.0.3
@@ -140,7 +140,28 @@ var util = require("util"); | ||
if (data[i]._source.title && data[i]._source.words) { | ||
//for source_type grants_* | ||
if (typeof data[i]._source.meta.award_floor != "number") delete data[i]._source.meta.award_floor; | ||
if (typeof data[i]._source.meta.award_ceiling != "number") delete data[i]._source.meta.award_ceiling; | ||
if (typeof data[i]._source.meta.estimated_funding != "number") delete data[i]._source.meta.estimated_funding; | ||
if (data[i]._source.meta.award_floor) { | ||
if (data[i]._source.meta.award_floor != 'none') { | ||
data[i]._source.meta.award_floor = (typeof data[i]._source.meta.award_floor != "number") ? parseInt(data[i]._source.meta.award_floor) : data[i]._source.meta.award_floor; | ||
} else { | ||
delete data[i]._source.meta.award_floor; | ||
} | ||
} | ||
if (data[i]._source.meta.award_ceiling) { | ||
if (data[i]._source.meta.award_ceiling != 'none') { | ||
data[i]._source.meta.award_ceiling = (typeof data[i]._source.meta.award_ceiling != "number") ? parseInt(data[i]._source.meta.award_ceiling) : data[i]._source.meta.award_ceiling; | ||
} else { | ||
delete data[i]._source.meta.award_ceiling; | ||
} | ||
} | ||
if (data[i]._source.meta.estimated_funding) { | ||
if (data[i]._source.meta.estimated_funding != 'none') { | ||
data[i]._source.meta.estimated_funding = (typeof data[i]._source.meta.estimated_funding != "number") ? parseInt(data[i]._source.meta.estimated_funding) : data[i]._source.meta.estimated_funding; | ||
} else { | ||
delete data[i]._source.meta.estimated_funding; | ||
} | ||
} | ||
delete data[i]._source.top_words; | ||
@@ -147,0 +168,0 @@ data01.push(data[i]); |
@@ -5,3 +5,3 @@ { | ||
"description": "from elasticdump 0.16.1", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"repository": { | ||
@@ -8,0 +8,0 @@ "type": "git", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
338991
2717