mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 01:47:00 +01:00
remove warning on revoke approval for all nfts (#16953)
Co-authored-by: EresDev <eresdev@hotmail.com>
This commit is contained in:
parent
dbe77289d3
commit
074c2934fe
@ -260,7 +260,6 @@ describe('Collectibles', function () {
|
||||
|
||||
// Confirm disabling set approval for all
|
||||
await driver.clickElement({ text: 'Confirm', tag: 'button' });
|
||||
await driver.clickElement({ text: 'Approve', tag: 'button' });
|
||||
|
||||
await driver.waitUntilXWindowHandles(2);
|
||||
await driver.switchToWindow(extension);
|
||||
|
@ -109,6 +109,7 @@ export default class ConfirmPageContainer extends Component {
|
||||
supportsEIP1559: PropTypes.bool,
|
||||
nativeCurrency: PropTypes.string,
|
||||
isBuyableChain: PropTypes.bool,
|
||||
isApprovalOrRejection: PropTypes.bool,
|
||||
};
|
||||
|
||||
async componentDidMount() {
|
||||
@ -186,6 +187,7 @@ export default class ConfirmPageContainer extends Component {
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
accountBalance,
|
||||
assetStandard,
|
||||
isApprovalOrRejection,
|
||||
} = this.props;
|
||||
|
||||
const shouldDisplayWarning =
|
||||
@ -354,7 +356,11 @@ export default class ConfirmPageContainer extends Component {
|
||||
<PageContainerFooter
|
||||
onCancel={onCancel}
|
||||
cancelText={t('reject')}
|
||||
onSubmit={isSetApproveForAll ? onSetApprovalForAll : onSubmit}
|
||||
onSubmit={
|
||||
isSetApproveForAll && isApprovalOrRejection
|
||||
? onSetApprovalForAll
|
||||
: onSubmit
|
||||
}
|
||||
submitText={t('confirm')}
|
||||
submitButtonType={
|
||||
isSetApproveForAll ? 'danger-primary' : 'primary'
|
||||
|
Loading…
Reference in New Issue
Block a user