Hash returns the SHA1 hash of a review comment.
()
| 183 | |
| 184 | // Hash returns the SHA1 hash of a review comment. |
| 185 | func (comment Comment) Hash() (string, error) { |
| 186 | bytes, err := comment.serialize() |
| 187 | return fmt.Sprintf("%x", sha1.Sum(bytes)), err |
| 188 | } |
| 189 | |
| 190 | // Set implenents flag.Value for the Range type |
| 191 | func (r *Range) Set(s string) error { |