Skip to content

Commit aa66ae3

Browse files
authored
Merge pull request #177 from nullun/fix/check-incentive-fee
fix: allow any consensus version when determining keyreg fee
2 parents fa69d7d + 43b79ba commit aa66ae3

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

ui/modals/partkey/transaction/controller.go

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -64,18 +64,13 @@ func (m ViewModel) Account() *algod.Account {
6464
return nil
6565
}
6666

67-
func (m ViewModel) IsIncentiveProtocol() bool {
68-
return m.State.Status.LastProtocolVersion == "https://github.com/algorandfoundation/specs/tree/236dcc18c9c507d794813ab768e467ea42d1b4d9"
69-
}
70-
7167
// Whether the 2A incentive fee should be added
7268
func (m ViewModel) ShouldAddIncentivesFee() bool {
7369
// conditions for 2A fee:
7470
// 1) incentives allowed by user: command line flag to disable incentives has not been passed
7571
// 2) online keyreg
76-
// 3) protocol supports incentives
77-
// 4) account is not already incentives eligible
78-
return m.State != nil && !m.State.IncentivesDisabled && !m.OfflineControls && m.IsIncentiveProtocol() && m.Account() != nil && !m.Account().IncentiveEligible
72+
// 3) account is not already incentives eligible
73+
return m.State != nil && !m.State.IncentivesDisabled && !m.OfflineControls && m.Account() != nil && !m.Account().IncentiveEligible
7974
}
8075

8176
func (m *ViewModel) UpdateState() {

0 commit comments

Comments
 (0)