#33028: ModelAdmin.init has self.opts, but it still nowerewhere else in
django.admin.contrib.options not used
-------------------------------------+-------------------------------------
     Reporter:  Maxim Danilov        |                    Owner:  Marcelo
         Type:                       |  Galigniana
  Cleanup/optimization               |                   Status:  assigned
    Component:  contrib.admin        |                  Version:  3.2
     Severity:  Normal               |               Resolution:
     Keywords:  admin, modeladmin    |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  1                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Marcelo Galigniana):

 * owner:  Maxim Danilov => Marcelo Galigniana


Comment:

 Hello!

 I can do the find/replace to see how the diff looks like.

 But I would suggest to do the opposite way: remove the use of `self.opts`
 and use `._meta` instead (which in my opinion it's easier; at least to get
 more consistency). What do you think?

 I did a quick search in my local project and I got:

 - For ".opts" -> **66** results in **11** files
 - For "model._meta" -> **980** results in **134** files
 - And just "._meta" -> **2215** results in **225** files

-- 
Ticket URL: <https://code.djangoproject.com/ticket/33028#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/067.083e5a8c658bf23288c76dd3fbc7bd11%40djangoproject.com.

Reply via email to