mirror of
https://github.com/go-admin-team/go-admin.git
synced 2026-10-04 06:22:02 +00:00
test
This commit is contained in:
@@ -14,16 +14,6 @@ import (
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
)
|
||||
|
||||
// 不建议使用的方法(即将过时)
|
||||
// Deprecated method (out of date)
|
||||
func StrToInt(err error, index string) int {
|
||||
result, err := strconv.Atoi(index)
|
||||
if err != nil {
|
||||
HasError(err, "string to int error"+err.Error(), -1)
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
func CompareHashAndPassword(e string, p string) (bool, error) {
|
||||
err := bcrypt.CompareHashAndPassword([]byte(e), []byte(p))
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user