<p>This PR continues on from <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="839730264" data-permission-text="Title is private" data-url="https://github.com/openstreetmap/openstreetmap-website/issues/3147" data-hovercard-type="pull_request" data-hovercard-url="/openstreetmap/openstreetmap-website/pull/3147/hovercard" href="https://github.com/openstreetmap/openstreetmap-website/pull/3147">#3147</a> by creating a PasswordsController (for password resets) and a ConfirmationsController.</p>
<p>Both these controllers could do with significant further refactoring, specifically to refactor to a resources approach (new, show, update, etc) instead of custom method names. This will also involve de-tangling the methods which currently take multiple http methods (GET, PUT) to do different things, which is a recurring source of complexity. But I've left that alone for now.</p>
<p>As before, the controller names are designed to align with Devise.</p>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href='https://github.com/openstreetmap/openstreetmap-website/pull/3165'>https://github.com/openstreetmap/openstreetmap-website/pull/3165</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Split password reset functionality into PasswordsController</li>
  <li>Move confirmation methods into ConfirmationsController</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-debf59904131dc89a88ab44cbb1d6deaaa5a7d70c0507f674080df62f7c8e41f">app/abilities/ability.rb</a>
    (4)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-8ac25145a80d1093fb7a8f1098aa9d5b0a1d70ced7333342a9ec569227d0a82f">app/controllers/concerns/session_methods.rb</a>
    (2)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-961c5d7e0310073ca00d502eda2687808102441be660a654cab29645fbcea019">app/controllers/confirmations_controller.rb</a>
    (137)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-e731908a3da0376adc4c661e2db98a148ef9be83a310f7abc2e157a481ca6132">app/controllers/passwords_controller.rb</a>
    (67)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-cfdccd0a9d5df5a43aaad2a35d36ebbe187c52ad5fdc9846fa189d04537adb6e">app/controllers/users_controller.rb</a>
    (181)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-55254045ba774e4c360d7bbfde054665072d2ab49abc3f21add15a37bba65a1c">app/mailers/user_mailer.rb</a>
    (6)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-596485415afaa248c73d36eeb3a5be71b78f19acaedd02fd5dbf9bad11145d18">app/views/confirmations/confirm.html.erb</a>
    (0)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-602689469c36018a5a0d7ecb5da2e2cf10694ed88b3ad50817d4b9a36448298d">app/views/confirmations/confirm_email.html.erb</a>
    (0)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-ac6a165909ff0368a37d435a422256a9f6f644fd8afa441ac363d0303fcc94d5">app/views/passwords/lost_password.html.erb</a>
    (0)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-45b690c94e6b1ea6bde7eb8ef2bbc7ac737495cc9fc1203e57eb6b8aab5d2744">app/views/passwords/reset_password.html.erb</a>
    (0)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-5654cfc158c888a40321c1e90f9ea3a0208ae80616b15ff0fa5e939b8f795e87">app/views/sessions/new.html.erb</a>
    (2)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-44438ce218f5287c58d0017f965d888715635d94280669896f75841fbd7b4cd7">config/locales/en.yml</a>
    (74)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-959bc9abc46a55332bb64d5155a79323afa75a50ec1a2137ddd22d926f62c6c5">config/routes.rb</a>
    (12)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-0d2e03e45f001516dac5c734d8c0cdbff7a73028598ed5d2f9f8623e52c6099e">test/controllers/confirmations_controller_test.rb</a>
    (339)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-b18721527d46de9b2eb33e182fbe7c7e0fb965c010817b030c047b92c0445c20">test/controllers/passwords_controller_test.rb</a>
    (153)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-2719d3c650da3c587f727ca3c105e6bc93a7113f85717bb15983543cf4f85ae5">test/controllers/users_controller_test.rb</a>
    (480)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165/files#diff-19aa16b7c7e0598a9b16e64733cafc53ac88bc34c658524342c0a0bffde8affc">test/integration/user_creation_test.rb</a>
    (42)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/3165.patch'>https://github.com/openstreetmap/openstreetmap-website/pull/3165.patch</a></li>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/3165.diff'>https://github.com/openstreetmap/openstreetmap-website/pull/3165.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/3165">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLMI4PNTSNIXIOS6EL3THRZEJANCNFSM42Q7U2UQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAK2OLLIORMOY3I6QBRGXT3THRZEJA5CNFSM42Q7U2U2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4MWQLFDQ.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/3165",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/3165",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>