Django

Code

Ticket #8344 (closed: fixed)

Opened 4 months ago

Last modified 3 months ago

contrib.auth.models.User.get_profile() throws AttributeError not SiteProfileNotAvailable

Reported by: jezdez Assigned to: jezdez
Milestone: 1.0 Component: Authentication
Version: SVN Keywords:
Cc: Triage Stage: Accepted
Has patch: 1 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

On line line 289 it checks if settings.AUTH_PROFILE_MODULE is set. This throws an AttributeError instead of the SiteProfileNotAvailable exception, if the setting is not given.

The attached patch fixes the issue.

Attachments

get_profile.r8366.diff (0.6 kB) - added by jezdez on 08/15/08 07:12:05.
initial patch to fix get_profile()

Change History

08/15/08 07:12:05 changed by jezdez

  • attachment get_profile.r8366.diff added.

initial patch to fix get_profile()

08/15/08 09:35:28 changed by jezdez

  • owner changed from nobody to jezdez.
  • needs_better_patch changed.
  • needs_tests changed.
  • needs_docs changed.

08/25/08 10:55:10 changed by mtredinnick

  • stage changed from Unreviewed to Accepted.
  • milestone set to 1.0.

08/25/08 11:57:00 changed by jacob

  • status changed from new to closed.
  • resolution set to fixed.

(In [8543]) Fixed #8344: make User.get_profile() work when settings.AUTH_PROFILE_MODULE is unset.


Add/Change #8344 (contrib.auth.models.User.get_profile() throws AttributeError not SiteProfileNotAvailable)




Change Properties
Action