mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2024-11-19 09:50:15 +01:00
REF: Don't async on componentDidMount
This commit is contained in:
parent
2a4c821d02
commit
b6d5dc88ea
@ -226,7 +226,7 @@ export default class WalletTransactions extends Component {
|
||||
};
|
||||
}
|
||||
|
||||
async componentDidMount() {
|
||||
componentDidMount() {
|
||||
this._unsubscribeFocus = this.props.navigation.addListener('focus', this.onFocus);
|
||||
this._unsubscribeBlur = this.props.navigation.addListener('blur', this.onBlur);
|
||||
|
||||
@ -234,8 +234,8 @@ export default class WalletTransactions extends Component {
|
||||
this.interval = setInterval(() => {
|
||||
this.setState(prev => ({ timeElapsed: prev.timeElapsed + 1 }));
|
||||
}, 60000);
|
||||
const isHandOffUseEnabled = await HandoffSettings.isHandoffUseEnabled();
|
||||
this.setState({ isHandOffUseEnabled, isLoading: false });
|
||||
HandoffSettings.isHandoffUseEnabled().then(enabled => this.setState({ isHandOffUseEnabled: enabled }));
|
||||
this.setState({ isLoading: false });
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user