import React from 'react';
import { withRouter } from 'react-router-dom';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';

import * as QueueActions from '../../actions/queue';
import * as PlayerActions from '../../actions/player';
import * as ToastActions from '../../actions/toasts';

import PlaylistView from '../../components/PlaylistView';

const PlaylistViewContainer = props => {
  return (
    <PlaylistView
      playlist={this.props.playlists.playlists[this.props.match.params.playlistId]}
      musicSources={this.props.musicSources}
      addTracks={this.props.actions.addPlaylistTracksToQueue}
      selectSong={this.props.actions.selectSong}
      startPlayback={this.props.actions.startPlayback}
      notify={this.props.actions.notify}
      clearQueue={this.props.actions.clearQueue}
      addToQueue={this.props.actions.addToQueue}
    />
  );
};

function mapStateToProps (state) {
  return {
    playlists: state.playlists,
    musicSources: state.plugin.plugins.musicSources
  };
}

function mapDispatchToProps (dispatch) {
  return {
    actions: bindActionCreators(Object.assign({}, QueueActions, PlayerActions, ToastActions), dispatch)
  };
}

export default withRouter(connect(mapStateToProps, mapDispatchToProps)(PlaylistViewContainer));

@@ -459,21 +459,16 @@
 aylist=%7B
-this.
 props.pl
@@ -485,21 +485,16 @@
 aylists%5B
-this.
 props.ma
@@ -537,21 +537,16 @@
 ources=%7B
-this.
 props.mu
@@ -574,21 +574,16 @@
 Tracks=%7B
-this.
 props.ac
@@ -632,21 +632,16 @@
 ctSong=%7B
-this.
 props.ac
@@ -679,21 +679,16 @@
 ayback=%7B
-this.
 props.ac
@@ -722,21 +722,16 @@
 notify=%7B
-this.
 props.ac
@@ -758,29 +758,24 @@
 clearQueue=%7B
-this.
 props.action
@@ -810,13 +810,8 @@
 ue=%7B
-this.
 prop

fix typo