token-validator: upload SSH key automatically validate latest challenge

This commit is contained in:
nemunaire 2019-03-25 22:46:12 +01:00
commit de1492e1db
2 changed files with 2 additions and 0 deletions

View file

@ -153,6 +153,7 @@ func (s Student) NewKey(key string) (k StudentKey, err error) {
} else if kid, err := res.LastInsertId(); err != nil {
return StudentKey{}, err
} else {
s.UnlockNewChallenge(len(challenges), "")
return StudentKey{kid, s.Id, key, time.Now()}, nil
}
}