- my $title = $score->{'title'};
- if (!defined($last_title) || $title ne $last_title) {
- push @allsongs, { title => $title, scores => [] };
+ my $song = $score->{'song'};
+
+ if (!defined($last_song) || $song != $last_song) {
+ push @allsongs, { song => $song, title => $score->{'title'}, scores => [] };