1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-22 19:26:13 +02:00

Fix disabled prop type in AddToken component (#8723)

The `disabled` prop being passed to the `PageContainer` component in
the render function for the `AddToken` component was a string in some
cases. It should always be a boolean. It has been cast to a boolean in
the one case where it was a string.
This commit is contained in:
Mark Stacey 2020-06-02 18:47:43 -03:00 committed by GitHub
parent 616a446832
commit e1c3778446
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -315,7 +315,7 @@ class AddToken extends Component {
title={this.context.t('addTokens')}
tabsComponent={this.renderTabs()}
onSubmit={() => this.handleNext()}
disabled={this.hasError() || !this.hasSelected()}
disabled={Boolean(this.hasError()) || !this.hasSelected()}
onCancel={() => {
clearPendingTokens()
history.push(mostRecentOverviewPage)