diff options
| author | Alex Gaynor <alex.gaynor@gmail.com> | 2014-04-02 08:32:51 -0700 |
|---|---|---|
| committer | Alex Gaynor <alex.gaynor@gmail.com> | 2014-04-02 08:32:51 -0700 |
| commit | c45607e9395ffd05c2cff454fdb55b3ab05dc0e3 (patch) | |
| tree | b086251fe9f40382ba59da087bea4f0234dc2221 | |
| parent | 9769337ca855f4831c855d6663ff3f688ee1652d (diff) | |
| parent | 6eb891f57ad8b13bded1c7d0f4683cf63ba18c76 (diff) | |
Merge pull request #2508 from tomwys/patch-1
Don't copy list for iteration.
| -rw-r--r-- | django/utils/autoreload.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/autoreload.py b/django/utils/autoreload.py index 119bebb148..94c74e582a 100644 --- a/django/utils/autoreload.py +++ b/django/utils/autoreload.py @@ -81,7 +81,7 @@ def gen_filenames(): Yields a generator over filenames referenced in sys.modules and translation files. """ - filenames = [filename.__file__ for filename in list(sys.modules.values()) + filenames = [filename.__file__ for filename in sys.modules.values() if hasattr(filename, '__file__')] if settings.USE_I18N: |
