<commit_before>import React, { Component } from 'react';

class AccountCard extends Component {

    selectAccount = (event) => {
        event.stopPropagation();
        event.nativeEvent.stopImmediatePropagation();       // You have to do this to intercept jQuery events
        this.props.selectAccount(this.props.account);
    }

    render() {
        const account = this.props.account;
        return (
            <div className="card" onClick={this.selectAccount}>
                <div className="account card-title">{account.bank} {account.account_type_text}</div>
                <dl className="labelvalue">
                    <dt className="label">Account number:</dt>
                    <dd className="value">****{account.account_number}</dd>
                    <dt className="label">Sort code:</dt>
                    <dd className="value">{account.sort_code}</dd>
                </dl>
            </div>
        );
    }
}

AccountCard.propTypes = {
    account: React.PropTypes.object,
    selectAccount: React.PropTypes.func,
};

export default AccountCard;<commit_msg>master remove sortcode from ransfers card list for postffice/cfo accounts<commit_after>import React, { Component } from 'react';

class AccountCard extends Component {

    selectAccount = (event) => {
        event.stopPropagation();
        event.nativeEvent.stopImmediatePropagation();       // You have to do this to intercept jQuery events
        this.props.selectAccount(this.props.account);
    }

    render() {
        const account = this.props.account;
        let sortCodeClass = account.sort_code ? '' : 'hidden';

        return (
            <div className="card" onClick={this.selectAccount}>
                <div className="account card-title">{account.bank} {account.account_type_text}</div>
                <dl className="labelvalue">
                    <dt className="label">Account number:</dt>
                    <dd className="value">****{account.account_number}</dd>
                    <div className={sortCodeClass}>
                        <dt className="label">Sort code:</dt>
                        <dd className="value">{account.sort_code}</dd>
                    </div>
                </dl>
            </div>
        );
    }
}

AccountCard.propTypes = {
    account: React.PropTypes.object,
    selectAccount: React.PropTypes.func,
};

export default AccountCard;
{'fraction_non_alphanumeric': 0.12452987881320518, 'fraction_numerical': 0.0, 'mean_word_length': 2.170860927152318, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 35, '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': '6960460', 'n_tokens_mistral': 628, 'n_tokens_neox': 607, 'n_words': 129}