<p>This PR refactors changeset comment handling into its own controller, and renames the controller methods accordingly. It doesn't change the API - that can wait for a future API version.</p>
<p><a class="user-mention" data-hovercard-type="user" data-hovercard-url="/hovercards?user_id=1109395" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/Nikerabbit">@Nikerabbit</a> this PR contains translation key renaming:</p>
<ul>
<li><code>changeset.rss.title_all</code> -> <code>changeset_comments.index.title_all</code></li>
<li><code>changeset.rss.title_particular</code> -> <code>changeset_comments.index.title_particular</code></li>
<li><code>changeset.rss.comment</code> -> <code>changeset_comments.comment.comment</code> and also  <code>changeset_comments.comments.comment</code></li>
<li><code>changeset.rss.commented_at_by_html</code> -> <code>changeset_comments.comment.commented_at_by_html</code></li>
</ul>
<p>For clarity, <code>changeset.rss.commented_at_html</code> and <code>changeset.rss.full</code> are removed as they were unused.</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/2050'>https://github.com/openstreetmap/openstreetmap-website/pull/2050</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Split changeset comment handling into a changeset_comments controller</li>
  <li>Rename comment to create</li>
  <li>Rename comments_feed to index</li>
  <li>Rename hide_comment and unhide_comment to destroy and restore</li>
  <li>Use relative translations for changeset comments</li>
  <li>Reduce the max class length after splitting the changeset comments controller tests out</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-0">.rubocop_todo.yml</a>
    (2)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-1">app/controllers/changeset_comments_controller.rb</a>
    (125)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-2">app/controllers/changeset_controller.rb</a>
    (132)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-3">app/views/changeset_comments/_comment.html.erb</a>
    (4)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-4">app/views/changeset_comments/_comments.rss.builder</a>
    (2)
  </li>
  <li>
    <strong>R</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-5">app/views/changeset_comments/index.rss.builder</a>
    (4)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-6">app/views/changeset_comments/timeout.atom.builder</a>
    (12)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-7">app/views/changeset_comments/timeout.html.erb</a>
    (1)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-8">config/locales/en.yml</a>
    (14)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-9">config/routes.rb</a>
    (10)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-10">test/controllers/changeset_comments_controller_test.rb</a>
    (251)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-11">test/controllers/changeset_controller_test.rb</a>
    (243)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/2050.patch'>https://github.com/openstreetmap/openstreetmap-website/pull/2050.patch</a></li>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/2050.diff'>https://github.com/openstreetmap/openstreetmap-website/pull/2050.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/2050">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABWnLeHPZ4ZPtvznFHswjORYjeX9lOdMks5usrZFgaJpZM4YSKrw">mute the thread</a>.<img src="https://github.com/notifications/beacon/ABWnLQ_wIUQALacC6zUJUz5y3Pl-8vDwks5usrZFgaJpZM4YSKrw.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/openstreetmap/openstreetmap-website","title":"openstreetmap/openstreetmap-website","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/openstreetmap/openstreetmap-website"}},"updates":{"snippets":[{"icon":"DESCRIPTION","message":"Split changeset comment handling into its own controller (#2050)"}],"action":{"name":"View Pull Request","url":"https://github.com/openstreetmap/openstreetmap-website/pull/2050"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/2050",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/2050",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "Split changeset comment handling into its own controller (#2050)",
"sections": [
{
"text": "",
"activityTitle": "**Andy Allan**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@gravitystorm",
"facts": [

]
},
{
"title": "Commit Summary",
"facts": [
{
"name": "19c2b92",
"value": "Split changeset comment handling into a changeset_comments controller"
},
{
"name": "b7e871c",
"value": "Rename comment to create"
},
{
"name": "4b0d56f",
"value": "Rename comments_feed to index"
},
{
"name": "04afeeb",
"value": "Rename hide_comment and unhide_comment to destroy and restore"
},
{
"name": "5cd417f",
"value": "Use relative translations for changeset comments"
},
{
"name": "47498ef",
"value": "Reduce the max class length after splitting the changeset comments controller tests out"
}
]
},
{
"title": "File Changes",
"facts": [
{
"name": "Modified",
"value": "[.rubocop_todo.yml](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-0) (2 changes)"
},
{
"name": "Added",
"value": "[app/controllers/changeset_comments_controller.rb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-1) (125 changes)"
},
{
"name": "Modified",
"value": "[app/controllers/changeset_controller.rb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-2) (132 changes)"
},
{
"name": "Renamed",
"value": "[app/views/changeset_comments/_comment.html.erb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-3) (4 changes)"
},
{
"name": "Renamed",
"value": "[app/views/changeset_comments/_comments.rss.builder](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-4) (2 changes)"
},
{
"name": "Renamed",
"value": "[app/views/changeset_comments/index.rss.builder](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-5) (4 changes)"
},
{
"name": "Added",
"value": "[app/views/changeset_comments/timeout.atom.builder](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-6) (12 changes)"
},
{
"name": "Added",
"value": "[app/views/changeset_comments/timeout.html.erb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-7) (1 changes)"
},
{
"name": "Modified",
"value": "[config/locales/en.yml](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-8) (14 changes)"
},
{
"name": "Modified",
"value": "[config/routes.rb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-9) (10 changes)"
},
{
"name": "Added",
"value": "[test/controllers/changeset_comments_controller_test.rb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-10) (251 changes)"
},
{
"name": "Modified",
"value": "[test/controllers/changeset_controller_test.rb](https://github.com/openstreetmap/openstreetmap-website/pull/2050/files#diff-11) (243 changes)"
}
]
}
],
"potentialAction": [
{
"name": "Add a comment",
"@type": "ActionCard",
"inputs": [
{
"isMultiLine": true,
"@type": "TextInput",
"id": "IssueComment",
"isRequired": false
}
],
"actions": [
{
"name": "Comment",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueComment\",\n\"repositoryFullName\": \"openstreetmap/openstreetmap-website\",\n\"issueId\": 2050,\n\"IssueComment\": \"{{IssueComment.value}}\"\n}"
}
]
},
{
"name": "Close pull request",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"PullRequestClose\",\n\"repositoryFullName\": \"openstreetmap/openstreetmap-website\",\n\"pullRequestId\": 2050\n}"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/openstreetmap/openstreetmap-website/pull/2050"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/openstreetmap/openstreetmap-website/pull/2050.patch"
}
],
"@type": "OpenUri",
"name": "View patch"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/openstreetmap/openstreetmap-website/pull/2050.diff"
}
],
"@type": "OpenUri",
"name": "View diff"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 407415536\n}"
}
],
"themeColor": "26292E"
}
]</script>