fix(accounts): reject wildcard model whitelist entries

Prevent adding models with wildcard characters and show an info message.
This commit is contained in:
Kayokoi authored and GitHub committed 2026-11-12 08:43:27 -08:00
1 parent 530c5e3a4f
commit 97705d147e
1 file changed
+4
@@ -278,6 +278,10 @@ const copyModelId = async (model: string) => {
const addCustom = () => {
const model = customModel.value.trim()
if (!model) return
if (model.includes('*')) {
appStore.showInfo(t('admin.accounts.modelWildcardNotSupported'))
return
}
if (props.modelValue.includes(model)) {
appStore.showInfo(t('admin.accounts.modelExists'))
return