stephrdev / django-userprofiles

BSD 3-Clause "New" or "Revised" License
47 stars 11 forks source link

Expire EmailVerifications / Raise 404 on invalid EmailVerification #15

Closed MarkusH closed 11 years ago

MarkusH commented 11 years ago

This pull request solves two problems in the emailverification app:

  1. A user is able to create multiple EmailVerification objects that are not expired. This is not the expected behavior. Only the most recent verification request should be valid.
  2. In the EmailChangeApproveView an invalid EmailVerification will correctly flash an error message. However, the response is a redirect to a page stating a successful request. The change will raise a HTTP404 if the request is invalid.