def histComic(comicURL): webObject = fetchWeb(comicURL,False) cache = Cache() cacheObject = cache.fetchCache(comicURL,None) if not compare(webObject, cacheObject): cache.storeCache(webObject) Scheduler.histComicNotification += 1 notification("Hist: " + comicURL) return None
def newComic(comicURLs): lastChange = None for url in comicURLs: cache = Cache() webObject = fetchWeb(url,False) cacheObject = cache.fetchCache(url,None) if not compare(webObject, cacheObject): cache.storeCache(webObject) lastChange = url if lastChange: Scheduler.newComicNotification += 1 notification("New: " + lastChange) return None