Use config cache for completion.web_history.exclude
On my machine, this speeds up regenerating from ~6min to ~25s.
This commit is contained in:
parent
108cc65bc6
commit
cd8fd8ab3c
@ -151,8 +151,8 @@ class WebHistory(sql.SqlTable):
|
||||
|
||||
def _is_excluded(self, url):
|
||||
"""Check if the given URL is excluded from the completion."""
|
||||
return any(pattern.matches(url)
|
||||
for pattern in config.val.completion.web_history.exclude)
|
||||
patterns = config.cache['completion.web_history.exclude']
|
||||
return any(pattern.matches(url) for pattern in patterns)
|
||||
|
||||
def _rebuild_completion(self):
|
||||
data = {'url': [], 'title': [], 'last_atime': []}
|
||||
|
Loading…
Reference in New Issue
Block a user