Improve error handling for list-contributors script
This commit is contained in:
parent
359989f235
commit
6b2ac15f56
@ -21,10 +21,6 @@ module.exports = async function(callback) {
|
||||
|
||||
try {
|
||||
const contributors = await kredits.Contributor.all()
|
||||
} catch(e) {
|
||||
callback(e);
|
||||
return;
|
||||
}
|
||||
|
||||
contributors.forEach((c) => {
|
||||
table.push([
|
||||
@ -38,6 +34,10 @@ module.exports = async function(callback) {
|
||||
c.ipfsHash
|
||||
])
|
||||
})
|
||||
} catch(e) {
|
||||
callback(e);
|
||||
return;
|
||||
}
|
||||
|
||||
console.log(table.toString())
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user