diff --git a/api-test/frontend/src/business/definition/components/assertion/ApiAssertions.vue b/api-test/frontend/src/business/definition/components/assertion/ApiAssertions.vue index eb7e8956a5..ff33c771f8 100644 --- a/api-test/frontend/src/business/definition/components/assertion/ApiAssertions.vue +++ b/api-test/frontend/src/business/definition/components/assertion/ApiAssertions.vue @@ -247,7 +247,12 @@ export default { this.assertions.jsonPath.push(jsonItem); }, clearJson() { - this.assertions.jsonPath = []; + if (this.assertions.jsonPath) { + const tmpArr = this.assertions.jsonPath.filter((item) => + !item.label + ); + this.assertions.jsonPath = tmpArr; + } }, }, };