Skip to content

Commit

Permalink
Merge pull request #392 from UniversityRadioYork/jp5457
Browse files Browse the repository at this point in the history
bodge schedule fix
  • Loading branch information
JP5457 authored Jan 4, 2025
2 parents 17d9320 + c094ddb commit 91a85d3
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions models/schedule_tabulate.go
Original file line number Diff line number Diff line change
Expand Up @@ -366,12 +366,14 @@ func buildList(schedule []*ScheduleItem, dates []time.Time) []WeekScheduleList {
// it comes from makescheduleslice see the s.fill line. needed otherwise the first show on monday will start at 6am on table view
// or not, theres jukeboxes coming from elsewhere aswell
if len(days[day].Shows) > 0 {
if days[day].Shows[len(days[day].Shows)-1].IsSustainer(){
days[day].Shows = days[day].Shows[:len(days[day].Shows) - 1]
}
if days[day].Shows[0].IsSustainer(){
days[day].Shows = days[day].Shows[1:]
}
if len(days[day].Shows) > 0 {
if days[day].Shows[len(days[day].Shows)-1].IsSustainer(){
days[day].Shows = days[day].Shows[:len(days[day].Shows) - 1]
}
}
}
}
return days
Expand Down

0 comments on commit 91a85d3

Please sign in to comment.