(core) Undo bug with summary table and raw data view

Summary:
Clicking undo/redo after converting a table to a summary table navigated
to the raw data view.

Test Plan: new test

Reviewers: georgegevoian, alexmojaki

Reviewed By: georgegevoian, alexmojaki

Subscribers: alexmojaki

Differential Revision: https://phab.getgrist.com/D3337
This commit is contained in:
Jarosław Sadziński
2022-03-24 19:33:53 +01:00
parent 546096fcc9
commit 64c9717ac1
2 changed files with 5 additions and 2 deletions

View File

@@ -163,6 +163,9 @@ function createNodes(docModel: DocModel, sections: MaybeSection[]) {
// Creates an array of LinkNode from a view section record.
function fromViewSectionRec(section: ViewSectionRec): LinkNode[] {
if (section.isDisposed()) {
return [];
}
const table = section.table.peek();
const ancestors = new Set<number>();