In latest SVN (as of writing) you see this in said file: 48 if getattr(new_class._meta, 'app_label', None) is None: 49 # Figure out the app_label by looking one level up. 50 # For 'django.contrib.sites.models', this would be 'sites'. 51 new_class._meta.app_label = model_module.__name__.split('.')[-2] I'm wondering, why the getattr? 48 if hasattr(new_class._meta, 'app_label'): 49 # Figure out the app_label by looking one level up. 50 # For 'django.contrib.sites.models', this would be 'sites'. 51 new_class._meta.app_label = model_module.__name__.split('.')[-2] works better since it doesn't return the data if it exists, or am I missing something with name lookups?
--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to [EMAIL PROTECTED] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-developers?hl=en -~----------~----~----~----~------~----~------~--~---