<p></p>
<p><b>@AntonKhorev</b> commented on this pull request.</p>

<hr>

<p>In <a href="https://github.com/openstreetmap/openstreetmap-website/pull/6316#discussion_r2271897958">app/controllers/changesets_controller.rb</a>:</p>
<pre style='color:#555'>> +    @ways = @changeset.old_ways
+                      .order(:way_id, :version)
+                      .offset(ELEMENTS_PER_PAGE * (@current_way_page - 1))
+                      .limit(ELEMENTS_PER_PAGE)
+  end
+
+  def load_relations
+    @relations_count = @changeset.actual_num_changed_relations
+    @current_relation_page = params[:relation_page].to_i.clamp(1, element_pages_count(@relations_count))
+    @relations = @changeset.old_relations
+                           .order(:relation_id, :version)
+                           .offset(ELEMENTS_PER_PAGE * (@current_relation_page - 1))
+                           .limit(ELEMENTS_PER_PAGE)
+  end
+
+  helper_method def element_pages_count(elements_count)
</pre>
<p dir="auto"><code class="notranslate">def</code> returns a symbol. Rails' documentation of <code class="notranslate">helper_method</code> <a href="https://github.com/rails/rails/commit/e976c489e6416cdc4714721df78dd43dd6d13d99">predates</a> <a href="https://stackoverflow.com/a/26216164" rel="nofollow">that</a>.</p>
<p dir="auto">Do you want an extra line of code for <code class="notranslate">helper_method</code> separate from the method itself?</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/6316#discussion_r2271897958">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLJWXUEBO4DOIJKKLU33NKMCHAVCNFSM6AAAAACDU7I76WVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZTCMJTG4ZTCOJUGQ">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/pull/6316/review/3113731944</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/6316#discussion_r2271897958",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/6316#discussion_r2271897958",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>