From 9a3238fb3be0ae9a3e2db48200ffbcd795045989 Mon Sep 17 00:00:00 2001 From: yflory Date: Mon, 5 Oct 2020 17:52:52 +0200 Subject: [PATCH] Trigger loadMoreHistory with semantic history --- www/common/sframe-common-history.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/www/common/sframe-common-history.js b/www/common/sframe-common-history.js index 279492c03..d171bcef4 100644 --- a/www/common/sframe-common-history.js +++ b/www/common/sframe-common-history.js @@ -328,9 +328,6 @@ define([ if (isNaN(i)) { return; } if (i > 0) { i = 0; } if (i < -(states.length - 2)) { i = -(states.length - 2); } - if (i <= -(states.length - 11)) { - loadMore(); - } var idx = getIndex(i); if (semantic && i !== c) { @@ -346,6 +343,10 @@ define([ } } + if (i <= -(states.length - 11)) { + loadMore(); + } + if (blockOnly) { return states[idx]; } var val = states[idx].getContent().doc;