Opened 9 years ago

Closed 9 years ago

#12796 closed (wontfix)

Change in django.db.models.options.get_verbose_name

Reported by: rafaelsdm Owned by: nobody
Component: contrib.admin Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


In order to make the code more readable I suggest to change the lambda function to a named function (def), simple like this:

def get_verbose_name(class_name):
   return re.sub('(((?<=[a-z])[A-Z])|([A-Z](?![A-Z]|$)))', ' \\1',class_name).lower().strip()

It came up in the Brazilian Django list[1].

[1] - pt_BR:

Change History (1)

comment:1 Changed 9 years ago by Russell Keith-Magee

Resolution: wontfix
Status: newclosed

I'm not sure I understand why this is any clearer, and my portuguese isn't good enough to follow the discussion on the referenced mailing list. If you can explain why this has caused confusion, please reopen.

Note: See TracTickets for help on using tickets.
Back to Top