mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-06 12:14:28 +08:00
allow custom app label for ForeignKey
This commit is contained in:
@@ -50,6 +50,9 @@ def initialize_django(settings_module: str) -> Tuple['Apps', 'LazySettings']:
|
||||
apps.get_models.cache_clear()
|
||||
apps.get_swappable_settings_name.cache_clear()
|
||||
|
||||
if not settings.configured:
|
||||
settings._setup()
|
||||
|
||||
apps.populate(settings.INSTALLED_APPS)
|
||||
|
||||
assert apps.apps_ready
|
||||
|
||||
Reference in New Issue
Block a user