content: import React from 'react';
  import { connect } from 'react-redux';
  import { addTrack } from '../actions/tracks';
  import { getSearchTracks } from '../reducers/search';
  import Playlist from '../components/Playlist';
  
  const mapStateToProps = (state) => ({
    userAudio: state.user.audio,
    searchAudio: getSearchTracks(state)
  });
  
  const mapDispatchToProps = {
    addTrack
  };
  
  const UserTracks = ({
    userAudio,
    searchAudio,
    addTrack
  }) => (
    <Playlist tracks={
      searchAudio.length ?
        searchAudio : userAudio
    } onClick={addTrack} />
  );
  
  export default connect(mapStateToProps, mapDispatchToProps)(UserTracks);