Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit bb18e44

Browse files
committed
Fix React warning by moving handler to each button
React is disturbed that the buttons don't have their own event handlers, so let's just move it there.
1 parent 9146992 commit bb18e44

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/async-components/views/dialogs/security/CreateSecretStorageDialog.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent {
470470
value={CREATE_STORAGE_OPTION_KEY}
471471
name="keyPassphrase"
472472
checked={this.state.passPhraseKeySelected === CREATE_STORAGE_OPTION_KEY}
473+
onChange={this._onKeyPassphraseChange}
473474
outlined
474475
>
475476
<div className="mx_CreateSecretStorageDialog_optionTitle">
@@ -488,6 +489,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent {
488489
value={CREATE_STORAGE_OPTION_PASSPHRASE}
489490
name="keyPassphrase"
490491
checked={this.state.passPhraseKeySelected === CREATE_STORAGE_OPTION_PASSPHRASE}
492+
onChange={this._onKeyPassphraseChange}
491493
outlined
492494
>
493495
<div className="mx_CreateSecretStorageDialog_optionTitle">
@@ -509,7 +511,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent {
509511
"Safeguard against losing access to encrypted messages & data by " +
510512
"backing up encryption keys on your server.",
511513
)}</p>
512-
<div className="mx_CreateSecretStorageDialog_primaryContainer" role="radiogroup" onChange={this._onKeyPassphraseChange}>
514+
<div className="mx_CreateSecretStorageDialog_primaryContainer" role="radiogroup">
513515
{optionKey}
514516
{optionPassphrase}
515517
</div>

0 commit comments

Comments
 (0)