feat(ssh/api): resolve circular structure issue
This commit is contained in:
parent
8ce5243c7b
commit
10aa9c539a
|
|
@ -66,7 +66,8 @@ class Api {
|
||||||
// crude stoppage attempt
|
// crude stoppage attempt
|
||||||
let response = await httpClient.get(endpoint, queryParams);
|
let response = await httpClient.get(endpoint, queryParams);
|
||||||
if (lastReponse) {
|
if (lastReponse) {
|
||||||
if (JSON.stringify(lastReponse) == JSON.stringify(response)) {
|
// Compare only the response body to avoid circular reference issues
|
||||||
|
if (JSON.stringify(lastReponse.body) == JSON.stringify(response.body)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -252,7 +252,8 @@ class FreeNASSshDriver extends ControllerZfsBaseDriver {
|
||||||
// crude stoppage attempt
|
// crude stoppage attempt
|
||||||
let response = await httpClient.get(endpoint, queryParams);
|
let response = await httpClient.get(endpoint, queryParams);
|
||||||
if (lastReponse) {
|
if (lastReponse) {
|
||||||
if (JSON.stringify(lastReponse) == JSON.stringify(response)) {
|
// Compare only the response body to avoid circular reference issues
|
||||||
|
if (JSON.stringify(lastReponse.body) == JSON.stringify(response.body)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue