<commit_before>class PlaylistsController < ApplicationController

  def create
  end

  def show
    p "I GOT TO THE SHOW PAGE!"
    RSpotify.authenticate(ENV['spotify_id'], ENV['spotify_secret'])
    user = User.find_by(:id => session[:user_id])
    spotify_user = RSpotify::User.find(user.spotify_id)
    # spotify_user.playlists.each { |x| p x.name }
    # base_url = "https://embed.spotify.com/?theme=white&uri=spotify:trackset:My Playlist:"
    playlist = RSpotify::Playlist.find(user.spotify_id, '2y0EFH0qtraCl8fbfhI5IJ')
    base_url = "https://embed.spotify.com/?uri=spotify:user:#{user.spotify_id}:playlist:#{playlist.id}"
    # playlist.tracks.each do |track|
    #   base_url += track.id
    #   p base_url
    # end
    respond_to do |format|
      format.json { render layout: false, json: {:base_url => base_url }}
    end
  end



  private

  def get_playlists(user_id)

  end
end

"https://embed.spotify.com/?ur=spotify:user: :playlist:"
<commit_msg>Take out commented debugging p's<commit_after>class PlaylistsController < ApplicationController

  def create
  end

  def show
    RSpotify.authenticate(ENV['spotify_id'], ENV['spotify_secret'])
    user = User.find_by(:id => session[:user_id])
    spotify_user = RSpotify::User.find(user.spotify_id)
    playlist = RSpotify::Playlist.find(user.spotify_id, '2y0EFH0qtraCl8fbfhI5IJ')
    base_url = "https://embed.spotify.com/?uri=spotify:user:#{user.spotify_id}:playlist:#{playlist.id}"
    respond_to do |format|
      format.json { render layout: false, json: {:base_url => base_url }}
    end
  end



  private

  def get_playlists(user_id)

  end
end

{'fraction_non_alphanumeric': 0.1330049261083744, 'fraction_numerical': 0.006157635467980296, 'mean_word_length': 4.110062893081761, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5649154', 'n_tokens_mistral': 619, 'n_tokens_neox': 584, 'n_words': 102}