admin/sync: don't show error when no hints directory to import

This commit is contained in:
nemunaire 2017-12-12 08:02:30 +01:00 committed by Pierre-Olivier Mercier
parent c4b6c1c268
commit b8b86fa71e

View file

@ -12,6 +12,8 @@ func SyncExerciceHints(i Importer, exercice fic.Exercice) []string {
if _, err := exercice.WipeHints(); err != nil {
errs = append(errs, err.Error())
} else if ! i.exists(path.Join(exercice.Path, "hints")) {
return errs
} else if hints, err := i.listDir(path.Join(exercice.Path, "hints")); err != nil {
errs = append(errs, err.Error())
} else {