diff --git a/pyfpdb/fpdb_import.py b/pyfpdb/fpdb_import.py index ffa06cff..d0837f82 100755 --- a/pyfpdb/fpdb_import.py +++ b/pyfpdb/fpdb_import.py @@ -125,7 +125,7 @@ class Importer: #Run full import on filelist def runImport(self): for file in self.filelist: - self.import_file_dict(file) + self.import_file_dict(file, self.filelist[file][0], self.filelist[file][1]) #Run import on updated files, then store latest update time. def runUpdated(self): @@ -140,17 +140,25 @@ class Importer: try: lastupdate = self.updated[file] if stat_info.st_mtime > lastupdate: - self.import_file_dict(file) + self.import_file_dict(file, self.filelist[file][0], self.filelist[file][1]) self.updated[file] = time() except: self.updated[file] = time() # This codepath only runs first time the file is found, if modified in the last # minute run an immediate import. if (time() - stat_info.st_mtime) < 60: - self.import_file_dict(file) + self.import_file_dict(file, self.filelist[file][0], self.filelist[file][1]) # This is now an internal function that should not be called directly. - def import_file_dict(self, file): + def import_file_dict(self, file, site, filter): + if(filter == "passthrough"): + self.import_fpdb_file(file, site) + else: + #Load filter, and run filtered file though main importer + self.import_fpdb_file(file, site) + + + def import_fpdb_file(self, file, site): starttime = time() last_read_hand=0 loc = 0