﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
35564	Improve readability of subclass identification in admin and auth checks	Jaap Roes	Jaap Roes	"While researching some code for another ticket I noticed noticed that the `contrib.admin` and `contrib.auth` `checks` modules have a very similar, but slightly different, bits of code:

[https://github.com/django/django/blob/e56a32b89bb7fadffdfaa2cdf12b4863ccd5af9b/django/contrib/admin/checks.py#L19-L44 _contains_subclass] and [https://github.com/django/django/blob/e56a32b89bb7fadffdfaa2cdf12b4863ccd5af9b/django/contrib/auth/checks.py#L12-L25 _subclass_index].

It took some careful reading, but they behave exactly the same, apart from one returning an index and the other a boolean.

I have a contribution that change these implementations, with the intent to make it easier to follow the flow. 

I tried to find a place in the Django codebase to have a shared implementation, but I haven't been able to identify one. It would be nice to have a canonical implementation of these functions."	Cleanup/optimization	closed	Core (System checks)	dev	Normal	fixed			Ready for checkin	1	0	0	0	0	0
