Skip to content

Commit ebf8356

Browse files
committed
Fix stac_version bug, release 0.4.1
1 parent 53a266a commit ebf8356

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Simple proof-of-concept to validate STAC Items, Catalogs, Collections and core e
44

55
## Versions
66

7-
**Current version: 0.4.0**
7+
**Current version: 0.4.1**
88

99
| STAC Node Validator Version | Supported STAC Versions |
1010
| --------------------------- | ----------------------- |

index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,12 @@ async function run() {
9393
fileValid = false;
9494
continue;
9595
}
96-
else if (compareVersions(version, '1.0.0-beta.2', '<')) {
96+
else if (compareVersions(data.stac_version, '1.0.0-beta.2', '<')) {
9797
console.error("-- " + id + ": Skipping; Can only validate STAC version >= 1.0.0-beta.2\n");
9898
continue;
9999
}
100100
else {
101-
console.log("-- " + id + " (" + version + ")");
101+
console.log("-- " + id + " (" + data.stac_version + ")");
102102
}
103103

104104
// Get all schema to validate against
@@ -109,7 +109,7 @@ async function run() {
109109

110110
for(let schema of schemas) {
111111
try {
112-
let loadArgs = isUrl(schema) ? [schema] : [schemaFolder, version, schema];
112+
let loadArgs = isUrl(schema) ? [schema] : [schemaFolder, data.stac_version, schema];
113113
let validate = await loadSchema(...loadArgs);
114114
let valid = validate(data);
115115
if (!valid) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "stac-node-validator",
3-
"version": "0.4.0",
3+
"version": "0.4.1",
44
"description": "STAC Validator for NodeJS",
55
"author": "Matthias Mohr",
66
"license": "Apache-2.0",

0 commit comments

Comments
 (0)