Use pointer instead of struct

This commit is contained in:
nemunaire 2021-03-07 12:39:38 +01:00
parent 853477e54a
commit 6d8f38d749
18 changed files with 187 additions and 142 deletions

View file

@ -47,7 +47,7 @@ func init() {
})
}
func hasSSHKeys(student adlin.Student, body []byte) (interface{}, error) {
func hasSSHKeys(student *adlin.Student, body []byte) (interface{}, error) {
if keys, err := student.GetKeys(); err != nil {
return nil, err
} else {
@ -141,7 +141,7 @@ func dumpAuthorizedKeysFile(w io.Writer) {
}
}
func dumpStdAuthorizedKeysFile(s adlin.Student, w io.Writer) {
func dumpStdAuthorizedKeysFile(s *adlin.Student, w io.Writer) {
seen := map[string]interface{}{}
if keys, _ := s.GetKeys(); keys != nil {