From 05c3c4e7041cfcc992a1aca0fd1ca6d191383733 Mon Sep 17 00:00:00 2001 From: splohmer <113967431+splohmer@users.noreply.github.com> Date: Sat, 23 Mar 2024 11:18:47 +0100 Subject: [PATCH] Fix of wrong calculation of new max rows if inserting a new row --- lib/src/sheet/sheet.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/sheet/sheet.dart b/lib/src/sheet/sheet.dart index 1a136c93..079c6717 100644 --- a/lib/src/sheet/sheet.dart +++ b/lib/src/sheet/sheet.dart @@ -655,9 +655,9 @@ class Sheet { _sheetData = Map>.from(_data); if (_maxRows - 1 <= rowIndex) { - _maxRows += 1; - } else { _maxRows = rowIndex + 1; + } else { + _maxRows += 1; } //_countRowsAndColumns();