refactor: code optimization

This commit is contained in:
meilin.huang
2025-04-23 20:36:32 +08:00
parent 798ab7d18b
commit 2170509d92
33 changed files with 445 additions and 380 deletions

View File

@@ -1,9 +1,9 @@
package api
import (
"mayfly-go/internal/pkg/utils"
"mayfly-go/pkg/biz"
"mayfly-go/pkg/req"
"mayfly-go/pkg/utils/cryptox"
)
type Common struct {
@@ -19,7 +19,7 @@ func (c *Common) ReqConfs() *req.Confs {
}
func (i *Common) RasPublicKey(rc *req.Ctx) {
publicKeyStr, err := cryptox.GetRsaPublicKey()
publicKeyStr, err := utils.GetRsaPublicKey()
biz.ErrIsNilAppendErr(err, "rsa - failed to genenrate public key")
rc.ResData = publicKeyStr
}