We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents cf1b9a5 + 4576333 commit 01a794dCopy full SHA for 01a794d
docs/examples/voting.rst
@@ -128,17 +128,17 @@ of votes.
128
// We found a loop in the delegation, not allowed.
129
require(to != msg.sender, "Found loop in delegation.");
130
}
131
-
+
132
Voter storage delegate_ = voters[to];
133
134
// Voters cannot delegate to accounts that cannot vote.
135
require(delegate_.weight >= 1);
136
137
// Since `sender` is a reference, this
138
// modifies `voters[msg.sender]`.
139
sender.voted = true;
140
sender.delegate = to;
141
142
if (delegate_.voted) {
143
// If the delegate already voted,
144
// directly add to the number of votes
0 commit comments