From 86d33c0f792f8f85bdd8f6276187568bb7cb6a04 Mon Sep 17 00:00:00 2001 From: Seth Call Date: Tue, 27 Oct 2015 09:48:07 -0500 Subject: [PATCH] * create mix not working; fixed --- .../JamTrackLandingScreen.js.jsx.coffee | 3 ++- web/app/views/layouts/minimal.html.erb | 16 +++++++--------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/web/app/assets/javascripts/react-components/JamTrackLandingScreen.js.jsx.coffee b/web/app/assets/javascripts/react-components/JamTrackLandingScreen.js.jsx.coffee index 95b0e290b..f0cad879d 100644 --- a/web/app/assets/javascripts/react-components/JamTrackLandingScreen.js.jsx.coffee +++ b/web/app/assets/javascripts/react-components/JamTrackLandingScreen.js.jsx.coffee @@ -217,7 +217,8 @@ rest = context.JK.Rest() onUser:(user) -> @setState({user: user}) - @doPurchasedSearch() + if context.JK.currentUserId? + @doPurchasedSearch() # Get artist names and build links #@rest.getJamTrackArtists({group_artist: true, per_page:100}) diff --git a/web/app/views/layouts/minimal.html.erb b/web/app/views/layouts/minimal.html.erb index ce624b881..f862e1c1e 100644 --- a/web/app/views/layouts/minimal.html.erb +++ b/web/app/views/layouts/minimal.html.erb @@ -56,15 +56,13 @@ <% if @websocket %> - if(!window.opener) { - JK.JamServer.connect() // singleton here defined in JamServer.js - .done(function() { - console.log("websocket connected") - }) - .fail(function() { - //console.log("websocket failed to connect") - }); - } + JK.JamServer.connect() // singleton here defined in JamServer.js + .done(function() { + console.log("websocket connected") + }) + .fail(function() { + //console.log("websocket failed to connect") + }); <% end %> })