Skip to content

Commit

Permalink
Merge pull request #1264 from akto-api-security/hotfix/fix_testing_ru…
Browse files Browse the repository at this point in the history
…ns_ui

handled check for collection id 0
  • Loading branch information
avneesh-akto authored Jul 10, 2024
2 parents 9213cf6 + 055e5ad commit 6b4df80
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,13 @@ const transform = {

let apiCollectionId = -1
if(Object.keys(data).length > 0){
apiCollectionId = data?.testingEndpoints?.apiCollectionId || data?.testingEndpoints?.workflowTest?.apiCollectionId || data?.testingEndpoints?.apisList[0]?.apiCollectionId
if(data?.testingEndpoints?.apiCollectionId !== undefined){
apiCollectionId = data?.testingEndpoints?.apiCollectionId
}else if(data?.testingEndpoints?.workflowTest?.apiCollectionId !== undefined){
apiCollectionId = data?.testingEndpoints?.workflowTest?.apiCollectionId
}else{
apiCollectionId = data?.testingEndpoints?.apisList[0]?.apiCollectionId
}
}
const iconObj = func.getTestingRunIconObj(state)

Expand Down

0 comments on commit 6b4df80

Please sign in to comment.