Skip to content

Commit 41a6e41

Browse files
committed
Fixed #4884 -- Fixed an initialisation problem when assigned to settings before
accessing them. Thanks, Noam Raphael. git-svn-id: http://code.djangoproject.com/svn/django/trunk@5713 bcc190cf-cafb-0310-a4f2-bffc1f526a37
1 parent 5dd9a2a commit 41a6e41

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

django/conf/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ def __setattr__(self, name, value):
3737
# __setattr__(), which would be an infinite loop.
3838
self.__dict__['_target'] = value
3939
else:
40+
if self._target is None:
41+
self._import_settings()
4042
setattr(self._target, name, value)
4143

4244
def _import_settings(self):

0 commit comments

Comments
 (0)