Commit 8a414b2
committed
Improve performance of LocalStorage._list_blobs
Current implementation globs over the entire root directory, but needs
files only with the given prefix. Globbing over the entire root
directory is very slow in case of a large number of files. 'Path.resolve()'
is used in an attempt to protect against directory traversal.1 parent 78e2cf7 commit 8a414b2
1 file changed
+3
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
| 55 | + | |
54 | 56 | | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
| 57 | + | |
60 | 58 | | |
61 | 59 | | |
62 | 60 | | |
| |||
0 commit comments