m-chrzan.xyz
aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMarcin Chrzanowski <m@m-chrzan.xyz>2021-09-12 15:30:19 +0200
committerMarcin Chrzanowski <m@m-chrzan.xyz>2021-09-12 15:30:19 +0200
commit12f960eebb19c25ea358fa5f60f1f3520cb1b85a (patch)
treedaae1fc05e3bf8406a31bc877f54af3c12af8b04 /src
parent7994abe07c61df326223171c3e9b036d11275664 (diff)
Sort songs by title
Diffstat (limited to 'src')
-rw-r--r--src/index.html.erb4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/index.html.erb b/src/index.html.erb
index 2008d11..5447ce6 100644
--- a/src/index.html.erb
+++ b/src/index.html.erb
@@ -1,9 +1,9 @@
Ĺšpiewnik polskiej muzyki tradycyjnej.
<ul>
-<%- songs.each_value do |song| -%>
+<%- songs.keys.sort.each do |song_id| -%>
<li>
- <a href='<%= path_to (song_html song.id) %>'><%= song.title %></a>
+ <a href='<%= path_to (song_html song_id) %>'><%= songs[song_id].title %></a>
</li>
<%- end -%>
</ul>