diff --git a/db/manifest b/db/manifest index 6fe7dc5ee..9f989d8be 100755 --- a/db/manifest +++ b/db/manifest @@ -126,4 +126,5 @@ track_download_counts.sql scores_mod_users2.sql user_bio.sql track_changes_counter.sql +scores_better_test_data.sql diff --git a/ruby/lib/jam_ruby/connection_manager.rb b/ruby/lib/jam_ruby/connection_manager.rb index 7862d5008..8ecee49f0 100644 --- a/ruby/lib/jam_ruby/connection_manager.rb +++ b/ruby/lib/jam_ruby/connection_manager.rb @@ -51,6 +51,7 @@ module JamRuby # we will reconnect the same music_session that the connection was previously in, # if it matches the same value currently in the database for music_session_id music_session_id_expression = 'NULL' + joined_session_at_expression = 'NULL' unless reconnect_music_session_id.nil? music_session_id_expression = "(CASE WHEN music_session_id='#{reconnect_music_session_id}' THEN music_session_id ELSE NULL END)" joined_session_at_expression = "(CASE WHEN music_session_id='#{reconnect_music_session_id}' THEN NOW() ELSE NULL END)" diff --git a/web/app/controllers/users_controller.rb b/web/app/controllers/users_controller.rb index 14018d9a1..fa26ef533 100644 --- a/web/app/controllers/users_controller.rb +++ b/web/app/controllers/users_controller.rb @@ -206,10 +206,10 @@ class UsersController < ApplicationController Slide.new("bands", "web/carousel_bands.jpg", "http://www.youtube.com/embed/eaYNM7p6Z5s") ] - @promo_buzz = Promotional.where(:type => 'JamRuby::PromoBuzz', :aasm_state => :active).order(:position) + @promo_buzz = Promotional.where(:type => 'JamRuby::PromoBuzz', :aasm_state => :active).where('latest_id IS NOT NULL').order(:position) if Rails.application.config.use_promos_on_homepage - @promo_latest = Promotional.where(:type => 'JamRuby::PromoLatest', :aasm_state => :active).order(:position).limit(10) + @promo_latest = Promotional.where(:type => 'JamRuby::PromoLatest', :aasm_state => :active).where('latest_id IS NOT NULL').order(:position).limit(10) else @promo_latest, start = Feed.index(nil, limit: 10) end