@@ -31,15 +31,13 @@ var (
31
31
lockedAmount = uint64(0)
32
32
)
33
33
34
- var (
35
- minimumAmount = uint64(1_000_000)
36
- )
34
+ var minimumAmount = uint64(1_000_000)
37
35
38
36
// Delegate delegates GNS tokens to a specified address.
39
37
// ref: https://docs.gnoswap.io/contracts/governance/staker.gno#delegate
40
38
func Delegate(to std.Address, amount uint64) {
41
39
if running {
42
- cleanDelegationStatHistory() // 함수명 변경
40
+ cleanDelegationStatHistory()
43
41
}
44
42
45
43
if amount == 0 {
@@ -92,15 +90,15 @@ func Delegate(to std.Address, amount uint64) {
92
90
// xGNS mint to caller
93
91
xgns.Mint(a2u(caller), amount)
94
92
95
- // prevAddr, prevPkgPath := getPrev()
96
- // std.Emit(
97
- // "Delegate",
98
- // "prevAddr", prevAddr,
99
- // "prevRealm", prevPkgPath,
100
- // "from", caller.String(),
101
- // "to", to.String(),
102
- // "amount", formatUint(amount),
103
- // )
93
+ prevAddr, prevPkgPath := getPrev()
94
+ std.Emit(
95
+ "Delegate",
96
+ "prevAddr", prevAddr,
97
+ "prevRealm", prevPkgPath,
98
+ "from", caller.String(),
99
+ "to", to.String(),
100
+ "amount", formatUint(amount),
101
+ )
104
102
}
105
103
106
104
// Redelegate redelegates xGNS from existing delegate to another.
0 commit comments