Demonstrate dis.fire() with view_user_settings

Like a5f3318f3b, this proves that the new dispatcher conversion works for fire-and-forget style dispatches too. This is another obvious-if-broken and generally safe conversion to make.

Other actions which can be dispatched this way have been excluded for reasons mentioned in the Action enum's comments.
This commit is contained in:
Travis Ralston 2020-05-13 21:07:19 -06:00
parent a5f3318f3b
commit e4835c4b03
10 changed files with 24 additions and 13 deletions

View file

@ -19,6 +19,7 @@ import PropTypes from 'prop-types';
import {_t} from "../../../languageHandler";
import * as sdk from "../../../index";
import dis from '../../../dispatcher/dispatcher';
import {Action} from "../../../dispatcher/actions";
export default class IntegrationsDisabledDialog extends React.Component {
static propTypes = {
@ -31,7 +32,7 @@ export default class IntegrationsDisabledDialog extends React.Component {
_onOpenSettingsClick = () => {
this.props.onFinished();
dis.dispatch({action: "view_user_settings"});
dis.fire(Action.ViewUserSettings);
};
render() {