Update LoadingScreen.js

This commit is contained in:
marcosrdz 2020-06-20 10:18:43 -04:00 committed by Overtorment
parent 9a367585a9
commit 7c3c015933

View file

@ -1,4 +1,4 @@
import React, { useState, useRef } from 'react'; import React, { useEffect, useState, useRef } from 'react';
import LottieView from 'lottie-react-native'; import LottieView from 'lottie-react-native';
import WalletMigrate from './screen/wallets/walletMigrate'; import WalletMigrate from './screen/wallets/walletMigrate';
import * as NavigationService from './NavigationService'; import * as NavigationService from './NavigationService';
@ -25,7 +25,10 @@ const LoadingScreen = () => {
} }
}; };
walletMigrate.current.start(); useEffect(() => {
walletMigrate.current.start();
}, [walletMigrate]);
return ( return (
<LottieView <LottieView
ref={loadingAnimation} ref={loadingAnimation}