From 2dbbf4e3d178617ca50ef931227a986145448c9f Mon Sep 17 00:00:00 2001
From: Jan Grewe <jan@faked.org>
Date: Sun, 7 Feb 2016 12:12:39 +0100
Subject: [PATCH] fix duplicate first 5 rows when switching between movies and
 shows and having scrolled down

---
 js/jquery.scrollstop.min.js | 2 --
 js/mediarack.js             | 2 ++
 2 files changed, 2 insertions(+), 2 deletions(-)
 delete mode 100644 js/jquery.scrollstop.min.js

diff --git a/js/jquery.scrollstop.min.js b/js/jquery.scrollstop.min.js
deleted file mode 100644
index 8b4a781..0000000
--- a/js/jquery.scrollstop.min.js
+++ /dev/null
@@ -1,2 +0,0 @@
-/*! Lazy Load 1.9.7 - MIT license - Copyright 2010-2015 Mika Tuupola */
-!function(){var a=jQuery.event.special,b="D"+ +new Date,c="D"+(+new Date+1);a.scrollstart={setup:function(){var c,d=function(b){var d=this,e=arguments;c?clearTimeout(c):(b.type="scrollstart",jQuery.event.dispatch.apply(d,e)),c=setTimeout(function(){c=null},a.scrollstop.latency)};jQuery(this).bind("scroll",d).data(b,d)},teardown:function(){jQuery(this).unbind("scroll",jQuery(this).data(b))}},a.scrollstop={latency:300,setup:function(){var b,d=function(c){var d=this,e=arguments;b&&clearTimeout(b),b=setTimeout(function(){b=null,c.type="scrollstop",jQuery.event.dispatch.apply(d,e)},a.scrollstop.latency)};jQuery(this).bind("scroll",d).data(c,d)},teardown:function(){jQuery(this).unbind("scroll",jQuery(this).data(c))}}}();
\ No newline at end of file
diff --git a/js/mediarack.js b/js/mediarack.js
index 40c7e0a..9464353 100644
--- a/js/mediarack.js
+++ b/js/mediarack.js
@@ -66,9 +66,11 @@ function showPage(page) {
   window.scrollTo(0, 0);
   switch(page) {
     case '#shows':
+      loadShows = false;
       getShows();
       break;
     case '#movies':
+      loadMovies = false;
       getMovies();
       break;
     default:
-- 
GitLab