Add kredits-formatter and additionally format balance #108
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "feature/kredits-formatter"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This adds a
balanceInt
value to the contributor data that has thetoken balance formatted as full Kredits. (similar to Ether)
any naming suggestions?
No need for
Promise.resolve
because everythen
returns a new Promise.return data;
should work.Yay!
As this is not a class, but just one formatting function, I'd call the file
format_kredits
and import it asformatKredits()
.What's the benefit of doing this here instead of before the return in the first
this
above?I think the convention is a dash for filenames in JS.
👍
formatKredits()
;
catAndMerge
returns a promise, so I only can do it in a nextthen
, no?I thought
getContributorById
already includes the balance. In which case it wouldn't matter what's returned afterwards, as it would already include the formatted balance beforehand.ah, true. before passing it to IPFS. 👍
There's a merge conflict here.
conflict resolved.