Skip to content

Commit

Permalink
Merge pull request Expensify#31872 from situchan/fix-transaction-comm…
Browse files Browse the repository at this point in the history
…ent-prop-type

[No QA] update transaction comment prop type
  • Loading branch information
MariaHCD authored Nov 30, 2023
2 parents 2febad0 + 3a5cbac commit d565caa
Showing 1 changed file with 17 additions and 14 deletions.
31 changes: 17 additions & 14 deletions src/components/transactionPropTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,28 @@ export default PropTypes.shape({
modifiedMerchant: PropTypes.string,

/** The comment object on the transaction */
comment: PropTypes.shape({
/** The text of the comment */
comment: PropTypes.string,
comment: PropTypes.oneOfType([
PropTypes.string,
PropTypes.shape({
/** The text of the comment */
comment: PropTypes.string,

/** The waypoints defining the distance request */
waypoints: PropTypes.shape({
/** The latitude of the waypoint */
lat: PropTypes.number,
/** The waypoints defining the distance request */
waypoints: PropTypes.shape({
/** The latitude of the waypoint */
lat: PropTypes.number,

/** The longitude of the waypoint */
lng: PropTypes.number,
/** The longitude of the waypoint */
lng: PropTypes.number,

/** The address of the waypoint */
address: PropTypes.string,
/** The address of the waypoint */
address: PropTypes.string,

/** The name of the waypoint */
name: PropTypes.string,
/** The name of the waypoint */
name: PropTypes.string,
}),
}),
}),
]),

/** The type of transaction */
type: PropTypes.oneOf(_.values(CONST.TRANSACTION.TYPE)),
Expand Down

0 comments on commit d565caa

Please sign in to comment.