A election/candidate.go => election/candidate.go +3 -0
@@ 0,0 1,3 @@
+package election
+
+type Candidate string
D election/merkle.go => election/merkle.go +0 -21
@@ 1,21 0,0 @@
-package election
-
-import (
- "crypto/sha256"
-
- "github.com/cbergoon/merkletree"
-)
-
-type Candidate string
-
-func (eo Candidate) CalculateHash() ([]byte, error) {
- h := sha256.New()
- if _, err := h.Write([]byte(eo)); err != nil {
- return nil, err
- }
- return h.Sum(nil), nil
-}
-
-func (eo Candidate) Equals(other merkletree.Content) (bool, error) {
- return eo == other.(Candidate), nil
-}