Merge pull request #2091 from G-Ambatte/fixComponentWillMount

Remove calls to deprecated `componentWillMount`
This commit is contained in:
Trevor Buckner authored and GitHub committed 2022-03-26 23:49:36 -04:00
commit a1e7da8d84
2 files changed
+9 -8

No files matched your search

+5 -2
View File
@@ -32,11 +32,14 @@ const Homebrew = createClass({
}
};
},
componentWillMount : function() {
global.account = this.props.account;
getInitialState : function(){
global.version = this.props.version;
global.account = this.props.account;
global.enable_v3 = this.props.enable_v3;
return {};
},
render : function (){
return (
<Router location={this.props.url}>
+4 -6
View File
@@ -14,12 +14,10 @@ const Navbar = createClass({
};
},
componentDidMount : function() {
//const isChrome = /Chrome/.test(navigator.userAgent) && /Google Inc/.test(navigator.vendor);
this.setState({
//showNonChromeWarning : !isChrome,
ver : window.version
});
getInitialState : function() {
return {
ver : global.version
};
},
/*