<commit_before>import React from 'react';
import { Link } from 'react-router';
import RaisedButton from 'material-ui/RaisedButton';
import getMuiTheme from 'material-ui/styles/getMuiTheme';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';

const Profile = React.createClass({
  handleTouchTap() {
    this.props.createChat(this.props.params.userId);
  },

  render() {

    const flexContainer = {
      display: 'flex',
      flexDirection: 'column',
      flexWrap: 'wrap',
      alignContent: 'center',
      alignItems: 'center',
      height: '70vh'
    }

    const styleButton = {
      display: 'flex',
      width: '100px',
      marginTop: '20px',
      margin: '0 auto'
    };

    const styleAvatar = {
      maxHeight: '40px',
      display: 'inline'
    };

    const styleTitle = {
      textAlign: 'center',
      fontFamily: 'Mallanna',
      fontSize: '25px',
      fontWeight: '200',
      marginTop: '0px',
      marginBottom: '0px',
      marginRight: '10px',
      position: 'inline'
    };

    const styleDiv = {
      marginTop: '10px',
      display: 'flex',
      justifyContent: 'center',
      borderBottom: '2px solid #ff7f66'
    };

    const styleBio = {
      textAlign: 'center',
      paddingLeft: '30px',
      paddingRight: '30px',
      marginLeft: '30px',
      marginRight: '30px',
      marginTop: '30px',
      marginBottom: '20px',
      fontFamily: 'Mallanna',
    };

    let user;

    if (this.props.user.id === Number.parseInt(this.props.params.userId)) {
      user = this.props.user;
    }

    else {
      const thisGiverArr = this.props.givers.filter((giver) => {
        return giver.userId === Number.parseInt(this.props.params.userId);
      });
      user = thisGiverArr[0];
    }

    return <div style={flexContainer}>
      <div>
        <div style={styleDiv}>
          <h1 style={styleTitle}>{user.firstName}</h1>
        </div>
        <p style={styleBio}>{user.aboutMe}</p>
        <RaisedButton
          label="Chat"
          onTouchTap={this.handleTouchTap}
          primary={true}
          style={styleButton}
        />
      </div>
    </div>
  }
});

export default Profile;
<commit_msg>Remove chat button from own profile<commit_after>import React from 'react';
import { Link } from 'react-router';
import RaisedButton from 'material-ui/RaisedButton';
import getMuiTheme from 'material-ui/styles/getMuiTheme';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';

const Profile = React.createClass({

  handleTouchTap() {
    this.props.createChat(this.props.params.userId);
  },

  render() {

    const flexContainer = {
      display: 'flex',
      flexDirection: 'column',
      flexWrap: 'wrap',
      alignContent: 'center',
      alignItems: 'center',
      height: '70vh'
    }

    const styleButton = {
      display: 'flex',
      width: '100px',
      marginTop: '20px',
      margin: '0 auto'
    };

    const styleAvatar = {
      maxHeight: '40px',
      display: 'inline'
    };

    const styleTitle = {
      textAlign: 'center',
      fontFamily: 'Mallanna',
      fontSize: '25px',
      fontWeight: '200',
      marginTop: '0px',
      marginBottom: '0px',
      marginRight: '10px',
      position: 'inline'
    };

    const styleDiv = {
      marginTop: '10px',
      display: 'flex',
      justifyContent: 'center',
      borderBottom: '2px solid #ff7f66'
    };

    const styleBio = {
      textAlign: 'center',
      paddingLeft: '30px',
      paddingRight: '30px',
      marginLeft: '30px',
      marginRight: '30px',
      marginTop: '30px',
      marginBottom: '20px',
      fontFamily: 'Mallanna',
    };

    const styleShowButton = {
      display: 'none'
    }

    let user;

    if (this.props.user.id === Number.parseInt(this.props.params.userId)) {
      styleButton.display = 'none';
      user = this.props.user;
    }

    else {
      const thisGiverArr = this.props.givers.filter((giver) => {
        return giver.userId === Number.parseInt(this.props.params.userId);
      });
      user = thisGiverArr[0];
    }

    return <div style={flexContainer}>
      <div>
        <div style={styleDiv}>
          <h1 style={styleTitle}>{user.firstName}</h1>
        </div>
        <p style={styleBio}>{user.aboutMe}</p>
        <RaisedButton
          label="Chat"
          onTouchTap={this.handleTouchTap}
          primary={true}
          style={styleButton}
        />
      </div>
    </div>
  }
});

export default Profile;

{'fraction_non_alphanumeric': 0.14129464285714285, 'fraction_numerical': 0.017857142857142856, 'mean_word_length': 2.3515332834704563, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 27, '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': '1521573', 'n_tokens_mistral': 1488, 'n_tokens_neox': 1431, 'n_words': 295}