fix extracting swarm hash

pull/1/head
yann300 5 years ago committed by GitHub
parent 3eda32c927
commit ef2d3ef2bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/lib/publishOnSwarm.js

@ -22,7 +22,7 @@ module.exports = (contract, fileManager, cb, swarmVerifiedPublishCallBack) => {
// find hash
var hash
try {
hash = metadata.sources[fileName].urls[0].match('bzzr://(.+)')[1]
hash = metadata.sources[fileName].urls[0].match('(bzzr|bzz-raw)://(.+)')[1]
} catch (e) {
return cb('Metadata inconsistency')
}

Loading…
Cancel
Save