diff options
| author | 2014-03-09 21:30:20 +0100 | |
|---|---|---|
| committer | 2014-03-09 21:30:20 +0100 | |
| commit | c3cac60b319189017c38b7d5e1d09f51ded96d0e (patch) | |
| tree | 51c9ff214b17dca7b2f1511c0a4fa95f6e954b5a /p/scripts | |
| parent | 670ee57b6288549ac611d53d86d8f5ffee641b0e (diff) | |
Autoload when less than 2 remaining articles
https://github.com/marienfressinaud/FreshRSS/issues/388
+ Simplify code
Diffstat (limited to 'p/scripts')
| -rw-r--r-- | p/scripts/main.js | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/p/scripts/main.js b/p/scripts/main.js index 6cc992379..b69ac0a2a 100644 --- a/p/scripts/main.js +++ b/p/scripts/main.js @@ -278,11 +278,8 @@ function next_entry() { new_active = old_active.length === 0 ? $(".flux:first") : old_active.nextAll(".flux:first"); toggleContent(new_active, old_active); - if (!auto_load_more) { - var last_active = $(".flux:last"); - if (last_active.attr("id") === new_active.attr("id")) { - load_more_posts(); - } + if (new_active.nextAll().length < 3) { + load_more_posts(); } } |
