diff --git a/chain/events/tscache.go b/chain/events/tscache.go
index 37487c180..9433e50f4 100644
--- a/chain/events/tscache.go
+++ b/chain/events/tscache.go
@@ -86,5 +86,5 @@ func (tsc *tipSetCache) best() *types.TipSet {
}
func normalModulo(n, m int) int {
- return (n%m + m) % m
+ return ((n % m) + m) % m
}
diff --git a/lotuspond/front/src/Address.js b/lotuspond/front/src/Address.js
index 47c17be34..6069bd29a 100644
--- a/lotuspond/front/src/Address.js
+++ b/lotuspond/front/src/Address.js
@@ -84,6 +84,11 @@ class Address extends React.Component {
return info
}
+ addColl = async () => {
+ const coll = await this.props.client.call('Filecoin.StatePledgeCollateral', [null])
+ this.props.addN(this.props.addr, coll)
+ }
+
render() {
let add20k =
if(this.props.addN) {
@@ -91,6 +96,7 @@ class Address extends React.Component {
if (this.props.add10k) {
add20k = {add20k} this.props.addN(this.props.addr, 2000000)}>[+2M]
add20k = {add20k} this.props.addN(this.props.addr, 20000000)}>[+20M]
+ add20k = {add20k} this.addColl()}>[+C]
}
}
let addr = truncAddr(this.props.addr, this.props.short ? 12 : 17)