<commit_before>import React, {Component} from 'react';
import {Panel, Glyphicon} from 'react-bootstrap';
import {connect} from 'react-redux';

class MovieInfo extends Component {
  constructor(props) {
    super(props);
  }


  getBudget() {
    return (<div><Glyphicon glyph="euro"/> {this.props.currentMovie.budget}</div>);
  }



  render() {
    let {currentMovie} = this.props;
    let movieInfo = null;
    let budget = null;
    if (currentMovie) {
      if (currentMovie.budget)
        budget = this.getBudget();

      movieInfo = (
        <Panel header={<h1>{currentMovie.title}</h1>}>
          <div className="MovieInfo">
            <h5>{currentMovie.overview}</h5>
            {budget}
          </div>
        </Panel>
      );
    } else {
      movieInfo = <div>NOTHING FOUND</div>
    }


    return (
      <div>
        {movieInfo}
      </div>
    );
  }
}

MovieInfo.defaultProps = {
  title: 'Please chose a movie',
  overview: '',
  index: 0
};

const mapStateToProps = (state) => ({
  ...state.playlist
});

export default connect(mapStateToProps)(MovieInfo);<commit_msg>Movie Rating included<commit_after>import React, {Component} from 'react';
import {Panel, Glyphicon} from 'react-bootstrap';
import {connect} from 'react-redux';

class MovieInfo extends Component {
  constructor(props) {
    super(props);
  }


  getBudget() {
    return (<div><Glyphicon glyph="euro"/> {this.props.currentMovie.budget}</div>);
  }



  render() {
    let {currentMovie} = this.props;
    let movieInfo = null;
    let budget = null;
    if (currentMovie) {
      if (currentMovie.budget)
        budget = this.getBudget();

      let voteNr = currentMovie.vote_average;
      let someText = "/10";

      movieInfo = (
        <Panel header={<h1>{currentMovie.title}</h1>}>
          <div className="MovieInfo">
            <h5>{currentMovie.overview}</h5>
            {budget}
            <h5> {'Average Rating: ' + voteNr + someText} </h5>
          </div>
        </Panel>
      );
    } else {
      movieInfo = <div>NOTHING FOUND</div>
    }


    return (
      <div>
        {movieInfo}
      </div>
    );
  }
}

MovieInfo.defaultProps = {
  title: 'Please chose a movie',
  overview: '',
  index: 0
};

const mapStateToProps = (state) => ({
  ...state.playlist
});

export default connect(mapStateToProps)(MovieInfo);
{'fraction_non_alphanumeric': 0.15194195475885616, 'fraction_numerical': 0.00597524541186513, 'mean_word_length': 2.5089820359281436, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 37, 'https://': 0, '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': '1770405', 'n_tokens_mistral': 809, 'n_tokens_neox': 756, 'n_words': 161}