given a string, return the md5 hash example: "hello" -> "5d41402abc4b2a76b9719d911017c592"
(str string)
| 137 | // given a string, return the md5 hash |
| 138 | // example: "hello" -> "5d41402abc4b2a76b9719d911017c592" |
| 139 | func MD5(str string) string { |
| 140 | data := []byte(str) |
| 141 | has := md5.Sum(data) |
| 142 | md5str1 := fmt.Sprintf("%x", has) |
| 143 | return md5str1 |
| 144 | } |
| 145 | |
| 146 | // check if a pth exists |
| 147 | func PathExists(path string) (bool, error) { |
nothing calls this directly
no outgoing calls
no test coverage detected