                 model.destroy()
 
               playlistEpisodes.listenTo Playlist, "playlist:newepisode", (model) ->
-                console.log("showManagePlaylist", model)
                 episodes.add newTrack
                 newTrack.save()
                 playlistEpisodes.render()
 
               playlistEpisodes.on "playlist:update", (childView, model) ->
-                console.log("playlist:update")
                 playlistEpisodes.children.findByModel(model).flash "success"
 
               Swabcast.sideBarRegion.close()

          mainPlaylistLayout = new View.ManagePlaylistLayout()

          mainPlaylistLayout.on "show", ->
            console.log(localStorage)
            fetchingPlaylist = Swabcast.request("entities:playlist")

            $.when(fetchingPlaylist).done (episodes) ->

                    newTrack.save()
                    Swabcast.commands.execute "player:setepisode", newTrack.get("id")  if tracks.at(0) is newTrack
                    #update the playlist in mainview
                    # Playlist.trigger "playlist:newepisode", newTrack
                    tracks.nowPlaying = newTrack  unless tracks.nowPlaying
                else
                  if apiResponse == "fail"
