diff options
author | Jason <jason.daurus@gmail.com> | 2016-06-17 06:01:29 +0800 |
---|---|---|
committer | Jason <jason.daurus@gmail.com> | 2016-06-17 06:01:29 +0800 |
commit | 6ad2f13341208b8460eae0dd0105c3109e773bae (patch) | |
tree | da4a75e02a3185b41a43bb0e80a5d64bec5aec74 /web/src/js/components | |
parent | cedac98b700efc6d1a38378e673626f07bff916d (diff) | |
download | mitmproxy-6ad2f13341208b8460eae0dd0105c3109e773bae.tar.gz mitmproxy-6ad2f13341208b8460eae0dd0105c3109e773bae.tar.bz2 mitmproxy-6ad2f13341208b8460eae0dd0105c3109e773bae.zip |
[web] fix settings ducks
Diffstat (limited to 'web/src/js/components')
-rw-r--r-- | web/src/js/components/ProxyApp.jsx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/web/src/js/components/ProxyApp.jsx b/web/src/js/components/ProxyApp.jsx index d7f640a3..1d27614f 100644 --- a/web/src/js/components/ProxyApp.jsx +++ b/web/src/js/components/ProxyApp.jsx @@ -3,6 +3,7 @@ import ReactDOM from "react-dom" import _ from "lodash" import { connect } from 'react-redux' +import { fetch as fetchSettings } from '../ducks/settings' import { Splitter } from "./common.js" import Header from "./Header" import EventLog from "./EventLog" @@ -51,6 +52,10 @@ class ProxyAppMain extends Component { return _.clone(this.props.location.query) } + componentWillMount() { + this.props.fetchSettings(); + } + /** * @todo connect websocket here * @todo listen to window's key events @@ -139,5 +144,8 @@ export default connect( state => ({ showEventLog: state.eventLog.visible, settings: state.settings.settings, - }) + }), + { + fetchSettings, + } )(ProxyAppMain) |