Skip to content

Commit

Permalink
Require report prop
Browse files Browse the repository at this point in the history
  • Loading branch information
neil-marcellini committed Sep 27, 2022
1 parent 2bef170 commit 9587df5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
9 changes: 7 additions & 2 deletions src/components/ReportWelcomeText.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,13 @@ const personalDetailsPropTypes = PropTypes.shape({

const propTypes = {
/** The report currently being looked at */
report: PropTypes.oneOfType([PropTypes.object]),
report: PropTypes.shape({
/** The id of the report */
reportID: PropTypes.number,

/** The report owner's email */
ownerEmail: PropTypes.string,
}).isRequired,

/* Onyx Props */

Expand All @@ -45,7 +51,6 @@ const propTypes = {
};

const defaultProps = {
report: {},
policies: {},
};

Expand Down
3 changes: 1 addition & 2 deletions src/pages/home/report/ReportActionItemCreated.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const propTypes = {

/** Whether the user is not an admin of policyExpenseChat chat */
isOwnPolicyExpenseChat: PropTypes.bool,
}),
}).isRequired,

/** Personal details of all the users */
personalDetails: PropTypes.objectOf(participantPropTypes),
Expand All @@ -35,7 +35,6 @@ const propTypes = {
}),
};
const defaultProps = {
report: {},
personalDetails: {},
policies: {},
};
Expand Down

0 comments on commit 9587df5

Please sign in to comment.