diff --git a/ui/components/app/app-components.scss b/ui/components/app/app-components.scss index 4f407569d..8110d8341 100644 --- a/ui/components/app/app-components.scss +++ b/ui/components/app/app-components.scss @@ -31,6 +31,7 @@ @import 'token-cell/token-cell'; @import 'transaction-activity-log/index'; @import 'transaction-breakdown/index'; +@import 'transaction-icon/transaction-icon'; @import 'transaction-list-item-details/index'; @import 'transaction-list-item/index'; @import 'transaction-list/index'; diff --git a/ui/components/app/transaction-icon/transaction-icon.js b/ui/components/app/transaction-icon/transaction-icon.js index 9311dd921..ec1b2a605 100644 --- a/ui/components/app/transaction-icon/transaction-icon.js +++ b/ui/components/app/transaction-icon/transaction-icon.js @@ -1,5 +1,6 @@ import React from 'react'; import PropTypes from 'prop-types'; +import { captureException } from '@sentry/browser'; import Approve from '../../ui/icon/approve-icon.component'; import Interaction from '../../ui/icon/interaction-icon.component'; import Receive from '../../ui/icon/receive-icon.component'; @@ -40,10 +41,35 @@ export default function TransactionIcon({ status, category }) { const Icon = ICON_MAP[category]; + if (!Icon) { + captureException( + Error( + `The category prop passed to TransactionIcon is not supported. The prop is: ${category}`, + ), + ); + + return
; + } + return