mirror of
https://github.com/rust-lang/rustlings.git
synced 2025-06-27 00:41:21 +02:00
Trim before checking if the hint is empty
This commit is contained in:
@ -38,7 +38,7 @@ fn check_info_file_exercises(info_file: &InfoFile) -> Result<hashbrown::HashSet<
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if exercise_info.hint.is_empty() {
|
if exercise_info.hint.trim().is_empty() {
|
||||||
bail!("The exercise `{}` has an empty hint. Please provide a hint or at least tell the user why a hint isn't needed for this exercise", exercise_info.name);
|
bail!("The exercise `{}` has an empty hint. Please provide a hint or at least tell the user why a hint isn't needed for this exercise", exercise_info.name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user