From 3b2913616bc8a91cc8f9a71ea26a3271e3145822 Mon Sep 17 00:00:00 2001 From: "Achim D. Brucker" Date: Tue, 5 Sep 2017 10:15:48 +0100 Subject: [PATCH] Skip first_seen if not defined. --- ExtensionCrawler/cdnjs.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ExtensionCrawler/cdnjs.py b/ExtensionCrawler/cdnjs.py index be88c85..9280536 100644 --- a/ExtensionCrawler/cdnjs.py +++ b/ExtensionCrawler/cdnjs.py @@ -193,10 +193,11 @@ def build_hash_map_of_lib(hashalg, archive, lib): 'library': lib, 'version': version, 'file': jsfile['filename'], - 'first_seen': jsfile['first_seen'] } if 'outphased' in jsfile: (hash_map[hashvalue])['outphased'] = jsfile['outphased'] + if 'first_seen' in jsfile: + (hash_map[hashvalue])['first_seen'] = jsfile['first_seen'] return hash_map