mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-18 04:43:55 +00:00
fix: a model can switch off every Default Feature the admin turned on (#32500)
The model editor dropped meta.defaultFeatureIds when the list was empty. When Admin Settings > Models > Model Defaults turns a default feature on, the backend fills in that default for any model without the key, so switching the last feature off on a model saved nothing and the admin default came back on reopen and in new chats. Keep the empty list when the admin default is not empty, so the model's choice is stored and overrides it.
This commit is contained in:
parent
e9233a9542
commit
a8dd8dbf98
1 changed files with 1 additions and 1 deletions
|
|
@ -450,7 +450,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
if (defaultFeatureIds.length > 0) {
|
||||
if (defaultFeatureIds.length > 0 || defaultMeta.defaultFeatureIds?.length > 0) {
|
||||
modelInfo.meta.defaultFeatureIds = defaultFeatureIds;
|
||||
} else {
|
||||
if (modelInfo.meta.defaultFeatureIds) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue