Only update originalMd5 for valid styles
This commit is contained in:
parent
c5a287a204
commit
31d37c8832
|
@ -156,8 +156,14 @@
|
|||
}
|
||||
// USO can't handle POST requests for style json
|
||||
return download(style.updateUrl, {body: null})
|
||||
// USO may not provide a correctly updated originalMd5 (#555)
|
||||
.then(text => Object.assign(tryJSONparse(text || '{}'), {originalMd5: md5}));
|
||||
.then(text => {
|
||||
const style = tryJSONparse(text);
|
||||
if (style) {
|
||||
// USO may not provide a correctly updated originalMd5 (#555)
|
||||
style.originalMd5 = md5;
|
||||
}
|
||||
return style;
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user