import { connect } from 'react-redux';
import {
  makeSelectCostInfoForUri,
  makeSelectFileInfoForUri,
  makeSelectClaimIsMine,
  doNotify,
} from 'lbry-redux';
import FileActions from './view';

const select = (state, props) => ({
  fileInfo: makeSelectFileInfoForUri(props.uri)(state),
  /* availability check is disabled due to poor performance, TBD if it dies forever or requires daemon fix */
  costInfo: makeSelectCostInfoForUri(props.uri)(state),
  claimIsMine: makeSelectClaimIsMine(props.uri)(state),
  claimId: props.claimId,
});

const perform = dispatch => ({
  openModal: (modal, props) => dispatch(doNotify(modal, props)),
});

export default connect(select, perform)(FileActions);

import { connect } from 'react-redux';
import {
  makeSelectCostInfoForUri,
  makeSelectFileInfoForUri,
  makeSelectClaimIsMine,
  doNotify,
} from 'lbry-redux';
import FileActions from './view';

const select = (state, props) => ({
  fileInfo: makeSelectFileInfoForUri(props.uri)(state),
  /* availability check is disabled due to poor performance, TBD if it dies forever or requires daemon fix */
  costInfo: makeSelectCostInfoForUri(props.uri)(state),
  claimIsMine: makeSelectClaimIsMine(props.uri)(state),
});

const perform = dispatch => ({
  openModal: (modal, props) => dispatch(doNotify(modal, props)),
});

export default connect(select, perform)(FileActions);

Remove selector property as is already being passed in from another component
Remove selector property as is already being passed in from another component
