From 80faeb960d47951a0fc027f5763b46f806f20f7a Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Wed, 17 Sep 2014 07:30:33 +0000 Subject: [PATCH] * update index for recent movies more regularly to catch new alternative names quickly --- BuildData.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/BuildData.groovy b/BuildData.groovy index 8f389cd1..3db1247f 100644 --- a/BuildData.groovy +++ b/BuildData.groovy @@ -130,7 +130,7 @@ def tmdb_index = csv(tmdb_txt, '\t', 1, [0..-1]) def tmdb = [] omdb.each{ m -> def sync = System.currentTimeMillis() - if (tmdb_index.containsKey(m[0]) && (sync - tmdb_index[m[0]][0].toLong()) < (180 * 24 * 60 * 60 * 1000L) ) { + if (tmdb_index.containsKey(m[0]) && (sync - tmdb_index[m[0]][0].toLong()) < ((m[2].toInteger() < 2000 ? 360 : 120) * 24 * 60 * 60 * 1000L) ) { tmdb << tmdb_index[m[0]] return } @@ -216,7 +216,7 @@ tvdb_updates.values().each{ update -> seriesNames += org.jsoup.Jsoup.connect("http://thetvdb.com/?tab=series&id=${update.id}").get() .select('#akaseries table tr table tr') .findAll{ it.select('td').any{ it.text() ==~ /en/ } } - .findResults{ it.select('td').first().text() } + .findResults{ it.select('td').first().text() } } def data = [update.time, update.id, imdbid, rating ?: 0, votes ?: 0] + seriesNames.findAll{ it != null && it.length() > 0 }