fix server creatiuon with userkp
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
ycc 2024-06-05 22:40:38 +02:00
parent 9b6caf4e62
commit d2bd4deb82

View File

@ -40,6 +40,7 @@ func CreateServerFromUrl(url string) *Server {
var is Server var is Server
is.Name = url is.Name = url
is.Url = url is.Url = url
is.UserKp = meowlib.NewKeyPair()
return &is return &is
} }
@ -48,6 +49,7 @@ func CreateServerFromUid(uid string) *Server {
var is Server var is Server
uidTable := strings.Split(uid, "@") //! Weak test, use regexp uidTable := strings.Split(uid, "@") //! Weak test, use regexp
is.Name = uid is.Name = uid
is.UserKp = meowlib.NewKeyPair()
if len(uidTable) == 2 { if len(uidTable) == 2 {
loginpw := strings.Split(uidTable[0], ":") loginpw := strings.Split(uidTable[0], ":")
is.Url = uidTable[1] is.Url = uidTable[1]