Skip to content

Commit

Permalink
remove unused onyx connections
Browse files Browse the repository at this point in the history
  • Loading branch information
arosiclair committed Sep 22, 2022
1 parent 864bb12 commit 8c94640
Showing 1 changed file with 5 additions and 36 deletions.
41 changes: 5 additions & 36 deletions src/components/RoomNameInput.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import React, {Component} from 'react';
import PropTypes from 'prop-types';
import {withOnyx} from 'react-native-onyx';
import CONST from '../CONST';
import ONYXKEYS from '../ONYXKEYS';
import compose from '../libs/compose';
import withLocalize, {withLocalizePropTypes} from './withLocalize';
import TextInput from './TextInput';

Expand All @@ -22,26 +19,6 @@ const propTypes = {

...withLocalizePropTypes,

/* Onyx Props */

/** All reports shared with the user */
reports: PropTypes.shape({
/** The report name */
reportName: PropTypes.string,

/** ID of the report */
reportID: PropTypes.number,
}).isRequired,

/** The policies which the user has access to and which the report could be tied to */
policies: PropTypes.shape({
/** The policy name */
name: PropTypes.string,

/** ID of the policy */
id: PropTypes.string,
}).isRequired,

/** A ref forwarded to the TextInput */
forwardedRef: PropTypes.func,
};
Expand Down Expand Up @@ -109,17 +86,9 @@ class RoomNameInput extends Component {
RoomNameInput.propTypes = propTypes;
RoomNameInput.defaultProps = defaultProps;

export default compose(
withLocalize,
withOnyx({
reports: {
key: ONYXKEYS.COLLECTION.REPORT,
},
policies: {
key: ONYXKEYS.COLLECTION.POLICY,
},
}),
)(React.forwardRef((props, ref) => (
export default withLocalize(
React.forwardRef((props, ref) => (
// eslint-disable-next-line react/jsx-props-no-spreading
<RoomNameInput {...props} forwardedRef={ref} />
)));
<RoomNameInput {...props} forwardedRef={ref} />
)),
);

0 comments on commit 8c94640

Please sign in to comment.