Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Michael Telatynski 2020-05-25 19:02:44 +01:00
parent 73d966443c
commit 148f215d4e

View file

@ -61,7 +61,7 @@ const useImageUrl = ({url, urls, idName, name, defaultToInitialLetter}) => {
// This means the state could be RECONNECTING, SYNCING, PREPARED or CATCHUP.
const reconnected = syncState !== "ERROR" && prevState !== syncState;
if (reconnected) {
setIndex(i => i > 0 ? 0 : i);
setIndex(0);
}
}, []);
useEventEmitter(cli, "sync", onClientSync);