mirror of
https://github.com/langgenius/dify.git
synced 2026-05-02 16:38:04 +08:00
Fix new variables in the conversation opener would override prompt_variables (#13191)
This commit is contained in:
@ -491,7 +491,7 @@ const Configuration: FC = () => {
|
||||
}, [formattingChangedDispatcher, setShowAppConfigureFeaturesModal])
|
||||
const handleAddPromptVariable = useCallback((variable: PromptVariable[]) => {
|
||||
const newModelConfig = produce(modelConfig, (draft: ModelConfig) => {
|
||||
draft.configs.prompt_variables = variable
|
||||
draft.configs.prompt_variables = [...draft.configs.prompt_variables, ...variable]
|
||||
})
|
||||
setModelConfig(newModelConfig)
|
||||
}, [modelConfig])
|
||||
|
||||
Reference in New Issue
Block a user