Feature/Fix-Invalid-TimeProgress-Name (#3)

Throw Exception when creating time progress with empty or null name.
Handle Exception when user creates new time progress or changes name.

Signed-off-by Andreas Fahrecker <AndreasFahrecker@gmail.com>
This commit is contained in:
Andreas Fahrecker
2020-11-21 19:57:47 +01:00
committed by GitHub
parent f43edc1ea7
commit 7cbd2eff40
5 changed files with 64 additions and 17 deletions

View File

@ -0,0 +1,7 @@
class TimeProgressInvalidNameException implements Exception {
final invalidName;
TimeProgressInvalidNameException(this.invalidName);
String errMsg() => "The name of a TimeProgress can't be: $invalidName";
}