mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-22 17:33:23 +01:00
Removed Confirm and Cancel events as they are not triggered anymore (#16777)
This commit is contained in:
parent
f7014a79fc
commit
40cba69128
@ -5,7 +5,6 @@ import { ObjectInspector } from 'react-inspector';
|
||||
import LedgerInstructionField from '../ledger-instruction-field';
|
||||
|
||||
import { MESSAGE_TYPE } from '../../../../shared/constants/app';
|
||||
import { EVENT } from '../../../../shared/constants/metametrics';
|
||||
import { getURLHostName } from '../../../helpers/utils/util';
|
||||
import { conversionUtil } from '../../../../shared/modules/conversion.utils';
|
||||
import { stripHexPrefix } from '../../../../shared/modules/hexstring-utils';
|
||||
@ -25,7 +24,6 @@ import SignatureRequestOriginalWarning from './signature-request-original-warnin
|
||||
export default class SignatureRequestOriginal extends Component {
|
||||
static contextTypes = {
|
||||
t: PropTypes.func.isRequired,
|
||||
trackEvent: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
static propTypes = {
|
||||
@ -191,18 +189,8 @@ export default class SignatureRequestOriginal extends Component {
|
||||
onSubmit = async (event) => {
|
||||
const { clearConfirmTransaction, history, mostRecentOverviewPage, sign } =
|
||||
this.props;
|
||||
const { trackEvent, type } = this.context;
|
||||
|
||||
await sign(event);
|
||||
trackEvent({
|
||||
category: EVENT.CATEGORIES.TRANSACTIONS,
|
||||
event: 'Confirm',
|
||||
properties: {
|
||||
action: 'Sign Request',
|
||||
legacy_event: true,
|
||||
type,
|
||||
},
|
||||
});
|
||||
clearConfirmTransaction();
|
||||
history.push(mostRecentOverviewPage);
|
||||
};
|
||||
@ -210,18 +198,8 @@ export default class SignatureRequestOriginal extends Component {
|
||||
onCancel = async (event) => {
|
||||
const { clearConfirmTransaction, history, mostRecentOverviewPage, cancel } =
|
||||
this.props;
|
||||
const { trackEvent, type } = this.context;
|
||||
|
||||
await cancel(event);
|
||||
trackEvent({
|
||||
category: EVENT.CATEGORIES.TRANSACTIONS,
|
||||
event: 'Cancel',
|
||||
properties: {
|
||||
action: 'Sign Request',
|
||||
legacy_event: true,
|
||||
type,
|
||||
},
|
||||
});
|
||||
clearConfirmTransaction();
|
||||
history.push(mostRecentOverviewPage);
|
||||
};
|
||||
@ -236,7 +214,7 @@ export default class SignatureRequestOriginal extends Component {
|
||||
txData: { type },
|
||||
hardwareWalletRequiresConnection,
|
||||
} = this.props;
|
||||
const { trackEvent, t } = this.context;
|
||||
const { t } = this.context;
|
||||
|
||||
return (
|
||||
<div className="request-signature__footer">
|
||||
@ -246,15 +224,6 @@ export default class SignatureRequestOriginal extends Component {
|
||||
className="request-signature__footer__cancel-button"
|
||||
onClick={async (event) => {
|
||||
await cancel(event);
|
||||
trackEvent({
|
||||
category: EVENT.CATEGORIES.TRANSACTIONS,
|
||||
event: 'Cancel',
|
||||
properties: {
|
||||
action: 'Sign Request',
|
||||
legacy_event: true,
|
||||
type,
|
||||
},
|
||||
});
|
||||
clearConfirmTransaction();
|
||||
history.push(mostRecentOverviewPage);
|
||||
}}
|
||||
@ -272,15 +241,6 @@ export default class SignatureRequestOriginal extends Component {
|
||||
this.setState({ showSignatureRequestWarning: true });
|
||||
} else {
|
||||
await sign(event);
|
||||
trackEvent({
|
||||
category: EVENT.CATEGORIES.TRANSACTIONS,
|
||||
event: 'Confirm',
|
||||
properties: {
|
||||
action: 'Sign Request',
|
||||
legacy_event: true,
|
||||
type,
|
||||
},
|
||||
});
|
||||
clearConfirmTransaction();
|
||||
history.push(mostRecentOverviewPage);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user