You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

18 lines
603 B

  1. from django.apps import AppConfig
  2. from django.contrib.auth.checks import check_user_model
  3. from django.core import checks
  4. from django.db.models.signals import post_migrate
  5. from django.utils.translation import ugettext_lazy as _
  6. from .management import create_permissions
  7. class AuthConfig(AppConfig):
  8. name = 'django.contrib.auth'
  9. verbose_name = _("Authentication and Authorization")
  10. def ready(self):
  11. post_migrate.connect(create_permissions,
  12. dispatch_uid="django.contrib.auth.management.create_permissions")
  13. checks.register(check_user_model, checks.Tags.models)