fix: Correct issues related to chat_flow_role version query

This commit is contained in:
lvxinyu.1117
2025-08-06 10:33:00 +08:00
parent 473ca91667
commit 9fdb3ecc79
2 changed files with 5 additions and 9 deletions

View File

@ -3915,11 +3915,9 @@ func (w *ApplicationService) GetChatFlowRole(ctx context.Context, req *workflow.
var version string
if wf.Meta.AppID != nil {
vl, err := GetWorkflowDomainSVC().GetWorkflowVersionsByConnector(ctx, mustParseInt64(req.GetConnectorID()), wf.ID, 1)
if err != nil {
if vl, err := GetWorkflowDomainSVC().GetWorkflowVersionsByConnector(ctx, mustParseInt64(req.GetConnectorID()), wf.ID, 1); err != nil {
return nil, err
}
if len(vl) > 0 {
} else if len(vl) > 0 {
version = vl[0]
}
}