admin/internet: prevent allowing zero countries
Massimo Melina committed
Jan 9, 2024 at 12:13 UTC
9fec33f8211b935b25f5c8616ba69de1ecbaf85a
1 file changed
+1
admin/src/InternetPage.ts
+1
@@ -80,6 +80,7 @@ export default function InternetPage() {
80
options: countryOptions,
81
renderOption: (v: any) => h(Country, { code: v.value, long: true }),
82
clearable: true,
83
+ getError: (v: any) => values[CFG.geo_allow] && !v?.length && "Cannot be empty",
84
},
85
values[CFG.geo_allow] != null && {
86
k: CFG.geo_allow_unknown,