| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -71,10 +71,10 @@ def checkcache(filename=None): | |||
| 71 | 71 | try: | |
| 72 | 72 | stat = os.stat(fullname) | |
| 73 | 73 | except OSError: | |
| 74 | - del cache[filename] | ||
| 74 | + cache.pop(filename, None) | ||
| 75 | 75 | continue | |
| 76 | 76 | if size != stat.st_size or mtime != stat.st_mtime: | |
| 77 | - del cache[filename] | ||
| 77 | + cache.pop(filename, None) | ||
| 78 | 78 | ||
| 79 | 79 | ||
| 80 | 80 | def updatecache(filename, module_globals=None): | |
@@ -84,7 +84,7 @@ def updatecache(filename, module_globals=None): | |||
| 84 | 84 | ||
| 85 | 85 | if filename in cache: | |
| 86 | 86 | if len(cache[filename]) != 1: | |
| 87 | - del cache[filename] | ||
| 87 | + cache.pop(filename, None) | ||
| 88 | 88 | if not filename or (filename.startswith('<') and filename.endswith('>')): | |
| 89 | 89 | return [] | |
| 90 | 90 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments