( credentialId: string, workspaceId: string )
| 79 | * fail fast at the affected block instead of with "credential not found". |
| 80 | */ |
| 81 | export async function clearCredentialRefs( |
| 82 | credentialId: string, |
| 83 | workspaceId: string |
| 84 | ): Promise<void> { |
| 85 | const needle = `%${credentialId}%` |
| 86 | |
| 87 | await Promise.all([ |
| 88 | clearInWorkflowBlocks(credentialId, workspaceId, needle), |
| 89 | clearInDeploymentVersions(credentialId, workspaceId, needle), |
| 90 | clearInPausedExecutions(credentialId, workspaceId, needle), |
| 91 | clearInWorkflowCheckpoints(credentialId, workspaceId, needle), |
| 92 | clearInKnowledgeConnectors(credentialId), |
| 93 | ]) |
| 94 | } |
| 95 | |
| 96 | async function clearInWorkflowBlocks( |
| 97 | credentialId: string, |
no test coverage detected