diff --git a/frontend/src/utils/async-table/async-table.js b/frontend/src/utils/async-table/async-table.js index 0e3c49685..68785f276 100644 --- a/frontend/src/utils/async-table/async-table.js +++ b/frontend/src/utils/async-table/async-table.js @@ -149,8 +149,7 @@ export class AsyncTable { } destroy() { - this._windowStorage.clear(); - this._historyStorage.clear(); + this._windowStorage.clear(this._windowStorage._options); this._eventManager.removeAllEventListenersFromUtil(); this._active = false; if (this._element.classList.contains(ASYNC_TABLE_INITIALIZED_CLASS)) diff --git a/frontend/src/utils/async-table/async-table.spec.js b/frontend/src/utils/async-table/async-table.spec.js index 61b476a9c..de5dc9b98 100644 --- a/frontend/src/utils/async-table/async-table.spec.js +++ b/frontend/src/utils/async-table/async-table.spec.js @@ -52,8 +52,8 @@ describe('AsyncTable', () => { }); it('should destroy Async Table', () => { - //asyncTable.destroy(); asyncTable.start(); + asyncTable.destroy(); expect(asyncTable._eventManager._registeredListeners.length).toBe(0); expect(asyncTable._element.classList).not.toContain(ASYNC_TABLE_INITIALIZED_CLASS); });