@@ -155,7 +155,7 @@ func CreateUser(request *msgs.CreateUserRequest, pgouser string) msgs.CreateUser
155155}
156156
157157// determine if the user passed in a valid password type
158- passwordType , err := msgs .GetPasswordType (request .PasswordType )
158+ passwordType , err := apiserver .GetPasswordType (request .PasswordType )
159159if err != nil {
160160response .Status .Code = msgs .Error
161161response .Status .Msg = err .Error ()
@@ -601,7 +601,7 @@ func UpdateUser(request *msgs.UpdateUserRequest, pgouser string) msgs.UpdateUser
601601}
602602
603603// determine if the user passed in a valid password type
604- if _ , err := msgs .GetPasswordType (request .PasswordType ); err != nil {
604+ if _ , err := apiserver .GetPasswordType (request .PasswordType ); err != nil {
605605response .Status .Code = msgs .Error
606606response .Status .Msg = err .Error ()
607607return response
@@ -940,7 +940,7 @@ func rotateExpiredPasswords(request *msgs.UpdateUserRequest, cluster *crv1.Pgclu
940940
941941// get the password type. the error is already evaluated in a called
942942// function
943- passwordType , _ := msgs .GetPasswordType (request .PasswordType )
943+ passwordType , _ := apiserver .GetPasswordType (request .PasswordType )
944944
945945// generate a new password. Check to see if the user passed in a particular
946946// length of the password, or passed in a password to rotate (though that
@@ -1072,7 +1072,7 @@ func updateUser(request *msgs.UpdateUserRequest, cluster *crv1.Pgcluster) msgs.U
10721072// Speaking of passwords...let's first determine if the user updated their
10731073// password. See generatePassword for how precedence is given for password
10741074// updates
1075- passwordType , _ := msgs .GetPasswordType (request .PasswordType )
1075+ passwordType , _ := apiserver .GetPasswordType (request .PasswordType )
10761076isChanged , password , hashedPassword , err := generatePassword (result .Username ,
10771077request .Password , passwordType , request .RotatePassword , request .PasswordLength )
10781078// in the off-chance there is an error generating the password, record it
0 commit comments