Fix showing a schedule without venue/rooms

This commit is contained in:
Henne Vogelsang 2016-02-06 18:15:11 +01:00
parent 813658fb19
commit 8e324ac1af

View file

@ -16,7 +16,11 @@ module Admin
return
end
@dates = @conference.start_date..@conference.end_date
@rooms = @venue.rooms
if @venue && @venue.rooms.any?
@rooms = @venue.rooms
else
@rooms = [ Room.new(name: 'No Rooms!', size: 0) ]
end
end
def update