Update model

This commit is contained in:
lorenz.stechauner committed 2023-05-13 22:51:20 +02:00
1 parent f49f7534e9
commit 4d78cdd8a5
15 files changed
+121 -33

No files matched your search

+1 -1
View File
@@ -67,7 +67,7 @@ namespace Elwig.Helpers {
return new(false, "PLZ zu kurz");
}
int plz = int.Parse(input.Text);
if (!ctx.Postleitzahlen.Any(p => p.Plz == plz)) {
if (ctx.Postleitzahlen.Find(plz) == null) {
return new(false, "Ungültige PLZ");
}
return new(true, null);