wallet: Exit SyncMetaData if there are no transactions to sync
wallet: Exit SyncMetaData if there are no transactions to sync

Instead of crash with an assertion error, simply exit the function
`SyncMetaData` if there is no metadata to sync.

Fixes #13110.

tjps/bitcoin,EthanHeilman/bitcoin,BTCGPU/BTCGPU,Kogser/bitcoin,bespike/litecoin,andreaskern/bitcoin,CryptArc/bitcoin,GlobalBoost/GlobalBoost,CryptArc/bitcoin,mruddy/bitcoin,OmniLayer/omnicore,wellenreiter01/Feathercoin,monacoinproject/monacoin,gjhiggins/vcoincore,sstone/bitcoin,randy-waterhouse/bitcoin,jamesob/bitcoin,andreaskern/bitcoin,instagibbs/bitcoin,tjps/bitcoin,apoelstra/bitcoin,litecoin-project/litecoin,tecnovert/particl-core,kazcw/bitcoin,pataquets/namecoin-core,vmp32k/litecoin,Flowdalic/bitcoin,pstratem/bitcoin,mruddy/bitcoin,mm-s/bitcoin,n1bor/bitcoin,myriadteam/myriadcoin,Kogser/bitcoin,n1bor/bitcoin,jmcorgan/bitcoin,Flowdalic/bitcoin,apoelstra/bitcoin,jtimon/bitcoin,MarcoFalke/bitcoin,bitcoinknots/bitcoin,vmp32k/litecoin,ajtowns/bitcoin,n1bor/bitcoin,guncoin/guncoin,Kogser/bitcoin,mitchellcash/bitcoin,digibyte/digibyte,gjhiggins/vcoincore,vmp32k/litecoin,mm-s/bitcoin,practicalswift/bitcoin,domob1812/huntercore,alecalve/bitcoin,droark/bitcoin,myriadcoin/myriadcoin,droark/bitcoin,peercoin/peercoin,domob1812/huntercore,ahmedbodi/vertcoin,kazcw/bitcoin,dscotese/bitcoin,JeremyRubin/bitcoin,monacoinproject/monacoin,peercoin/peercoin,h4x3rotab/BTCGPU,guncoin/guncoin,RHavar/bitcoin,cdecker/bitcoin,kallewoof/bitcoin,wellenreiter01/Feathercoin,MeshCollider/bitcoin,RHavar/bitcoin,ericshawlinux/bitcoin,tecnovert/particl-core,myriadteam/myriadcoin,Flowdalic/bitcoin,jnewbery/bitcoin,FeatherCoin/Feathercoin,domob1812/namecore,GroestlCoin/GroestlCoin,JeremyRubin/bitcoin,untrustbank/litecoin,monacoinproject/monacoin,CryptArc/bitcoin,thrasher-/litecoin,digibyte/digibyte,midnightmagic/bitcoin,afk11/bitcoin,sebrandon1/bitcoin,lateminer/bitcoin,randy-waterhouse/bitcoin,particl/particl-core,namecoin/namecoin-core,MeshCollider/bitcoin,jlopp/statoshi,achow101/bitcoin,fujicoin/fujicoin,achow101/bitcoin,OmniLayer/omnicore,peercoin/peercoin,alecalve/bitcoin,fujicoin/fujicoin,BTCGPU/BTCGPU,mm-s/bitcoin,digibyte/digibyte,lbryio/lbrycrd,GlobalBoost/GlobalBoost,n1bor/bitcoin,n1bor/bitcoin,dscotese/bitcoin,jnewbery/bitcoin,GroestlCoin/bitcoin,bitcoinsSG/bitcoin,myriadcoin/myriadcoin,jmcorgan/bitcoin,yenliangl/bitcoin,jlopp/statoshi,domob1812/huntercore,jlopp/statoshi,bitcoin/bitcoin,anditto/bitcoin,instagibbs/bitcoin,GlobalBoost/GlobalBoost,joshrabinowitz/bitcoin,untrustbank/litecoin,Bushstar/UFO-Project,fanquake/bitcoin,afk11/bitcoin,domob1812/bitcoin,qtumproject/qtum,vertcoin/vertcoin,EthanHeilman/bitcoin,sipsorcery/bitcoin,cdecker/bitcoin,guncoin/guncoin,droark/bitcoin,untrustbank/litecoin,pstratem/bitcoin,jonasschnelli/bitcoin,sebrandon1/bitcoin,myriadcoin/myriadcoin,practicalswift/bitcoin,mruddy/bitcoin,vertcoin/vertcoin,Christewart/bitcoin,jlopp/statoshi,untrustbank/litecoin,gjhiggins/vcoincore,midnightmagic/bitcoin,fujicoin/fujicoin,domob1812/namecore,JeremyRubin/bitcoin,jtimon/bitcoin,gjhiggins/vcoincore,prusnak/bitcoin,mm-s/bitcoin,achow101/bitcoin,gjhiggins/vcoincore,jambolo/bitcoin,bitcoinknots/bitcoin,instagibbs/bitcoin,vertcoin/vertcoin,digibyte/digibyte,ElementsProject/elements,qtumproject/qtum,anditto/bitcoin,CryptArc/bitcoin,JeremyRubin/bitcoin,bitcoinknots/bitcoin,domob1812/namecore,AkioNak/bitcoin,myriadteam/myriadcoin,dscotese/bitcoin,kazcw/bitcoin,AkioNak/bitcoin,achow101/bitcoin,ElementsProject/elements,jmcorgan/bitcoin,peercoin/peercoin,thrasher-/litecoin,afk11/bitcoin,kallewoof/bitcoin,fujicoin/fujicoin,ericshawlinux/bitcoin,FeatherCoin/Feathercoin,Kogser/bitcoin,CryptArc/bitcoin,jamesob/bitcoin,jonasschnelli/bitcoin,rawodb/bitcoin,midnightmagic/bitcoin,pstratem/bitcoin,jonasschnelli/bitcoin,pstratem/bitcoin,randy-waterhouse/bitcoin,prusnak/bitcoin,randy-waterhouse/bitcoin,jlopp/statoshi,myriadteam/myriadcoin,tjps/bitcoin,alecalve/bitcoin,tecnovert/particl-core,qtumproject/qtum,GroestlCoin/GroestlCoin,yenliangl/bitcoin,jnewbery/bitcoin,OmniLayer/omnicore,joshrabinowitz/bitcoin,bitcoinknots/bitcoin,bitcoin/bitcoin,joshrabinowitz/bitcoin,r8921039/bitcoin,MeshCollider/bitcoin,pataquets/namecoin-core,namecoin/namecoin-core,rnicoll/bitcoin,sstone/bitcoin,randy-waterhouse/bitcoin,rnicoll/bitcoin,GlobalBoost/GlobalBoost,RHavar/bitcoin,prusnak/bitcoin,jambolo/bitcoin,randy-waterhouse/bitcoin,practicalswift/bitcoin,sipsorcery/bitcoin,jtimon/bitcoin,tecnovert/particl-core,lbryio/lbrycrd,myriadteam/myriadcoin,namecoin/namecoin-core,mitchellcash/bitcoin,h4x3rotab/BTCGPU,GlobalBoost/GlobalBoost,r8921039/bitcoin,sstone/bitcoin,ericshawlinux/bitcoin,lbryio/lbrycrd,andreaskern/bitcoin,jonasschnelli/bitcoin,droark/bitcoin,Kogser/bitcoin,lateminer/bitcoin,sstone/bitcoin,cdecker/bitcoin,GroestlCoin/bitcoin,domob1812/bitcoin,rnicoll/dogecoin,wellenreiter01/Feathercoin,lbryio/lbrycrd,anditto/bitcoin,mitchellcash/bitcoin,jonasschnelli/bitcoin,guncoin/guncoin,rnicoll/dogecoin,particl/particl-core,Bushstar/UFO-Project,DigitalPandacoin/pandacoin,BTCGPU/BTCGPU,monacoinproject/monacoin,EthanHeilman/bitcoin,DigitalPandacoin/pandacoin,mruddy/bitcoin,Christewart/bitcoin,rnicoll/bitcoin,MeshCollider/bitcoin,qtumproject/qtum,wellenreiter01/Feathercoin,rnicoll/dogecoin,ericshawlinux/bitcoin,litecoin-project/litecoin,GroestlCoin/bitcoin,sipsorcery/bitcoin,JeremyRubin/bitcoin,bespike/litecoin,RHavar/bitcoin,Bushstar/UFO-Project,OmniLayer/omnicore,bitcoin/bitcoin,particl/particl-core,bitcoinknots/bitcoin,Bushstar/UFO-Project,DigitalPandacoin/pandacoin,rawodb/bitcoin,andreaskern/bitcoin,namecoin/namecoin-core,peercoin/peercoin,cdecker/bitcoin,GroestlCoin/GroestlCoin,bespike/litecoin,anditto/bitcoin,fujicoin/fujicoin,joshrabinowitz/bitcoin,rnicoll/bitcoin,ericshawlinux/bitcoin,lateminer/bitcoin,midnightmagic/bitcoin,Sjors/bitcoin,fanquake/bitcoin,ElementsProject/elements,rnicoll/bitcoin,achow101/bitcoin,Xekyo/bitcoin,particl/particl-core,fanquake/bitcoin,EthanHeilman/bitcoin,kallewoof/bitcoin,AkioNak/bitcoin,vertcoin/vertcoin,Kogser/bitcoin,digibyte/digibyte,AkioNak/bitcoin,domob1812/bitcoin,anditto/bitcoin,particl/particl-core,AkioNak/bitcoin,mm-s/bitcoin,jtimon/bitcoin,achow101/bitcoin,Sjors/bitcoin,Christewart/bitcoin,bespike/litecoin,apoelstra/bitcoin,EthanHeilman/bitcoin,r8921039/bitcoin,sebrandon1/bitcoin,mitchellcash/bitcoin,MarcoFalke/bitcoin,jmcorgan/bitcoin,GlobalBoost/GlobalBoost,tecnovert/particl-core,practicalswift/bitcoin,r8921039/bitcoin,thrasher-/litecoin,qtumproject/qtum,ahmedbodi/vertcoin,litecoin-project/litecoin,cdecker/bitcoin,GroestlCoin/bitcoin,tjps/bitcoin,bitcoin/bitcoin,qtumproject/qtum,mm-s/bitcoin,afk11/bitcoin,guncoin/guncoin,vmp32k/litecoin,domob1812/namecore,MarcoFalke/bitcoin,fanquake/bitcoin,litecoin-project/litecoin,yenliangl/bitcoin,droark/bitcoin,h4x3rotab/BTCGPU,lateminer/bitcoin,jnewbery/bitcoin,sebrandon1/bitcoin,pataquets/namecoin-core,myriadcoin/myriadcoin,monacoinproject/monacoin,namecoin/namecore,JeremyRubin/bitcoin,domob1812/huntercore,namecoin/namecore,digibyte/digibyte,vertcoin/vertcoin,particl/particl-core,ericshawlinux/bitcoin,Sjors/bitcoin,nikkitan/bitcoin,jambolo/bitcoin,rawodb/bitcoin,Xekyo/bitcoin,bespike/litecoin,sipsorcery/bitcoin,rnicoll/dogecoin,Flowdalic/bitcoin,namecoin/namecore,DigitalPandacoin/pandacoin,h4x3rotab/BTCGPU,OmniLayer/omnicore,vmp32k/litecoin,domob1812/namecore,kazcw/bitcoin,bitcoinsSG/bitcoin,GroestlCoin/bitcoin,jambolo/bitcoin,sstone/bitcoin,myriadteam/myriadcoin,kazcw/bitcoin,Christewart/bitcoin,h4x3rotab/BTCGPU,kallewoof/bitcoin,nikkitan/bitcoin,FeatherCoin/Feathercoin,nikkitan/bitcoin,rawodb/bitcoin,vertcoin/vertcoin,Sjors/bitcoin,rawodb/bitcoin,andreaskern/bitcoin,dscotese/bitcoin,sstone/bitcoin,alecalve/bitcoin,Sjors/bitcoin,ahmedbodi/vertcoin,h4x3rotab/BTCGPU,namecoin/namecoin-core,bitcoin/bitcoin,fujicoin/fujicoin,MarcoFalke/bitcoin,myriadcoin/myriadcoin,AkioNak/bitcoin,myriadcoin/myriadcoin,namecoin/namecore,litecoin-project/litecoin,ahmedbodi/vertcoin,domob1812/bitcoin,BTCGPU/BTCGPU,RHavar/bitcoin,nikkitan/bitcoin,MarcoFalke/bitcoin,GroestlCoin/bitcoin,MeshCollider/bitcoin,peercoin/peercoin,lateminer/bitcoin,practicalswift/bitcoin,OmniLayer/omnicore,afk11/bitcoin,Bushstar/UFO-Project,jlopp/statoshi,prusnak/bitcoin,sebrandon1/bitcoin,alecalve/bitcoin,thrasher-/litecoin,nikkitan/bitcoin,RHavar/bitcoin,MarcoFalke/bitcoin,MeshCollider/bitcoin,Bushstar/UFO-Project,r8921039/bitcoin,Kogser/bitcoin,tjps/bitcoin,lbryio/lbrycrd,ajtowns/bitcoin,Xekyo/bitcoin,bitcoinsSG/bitcoin,pstratem/bitcoin,GlobalBoost/GlobalBoost,lateminer/bitcoin,jamesob/bitcoin,alecalve/bitcoin,guncoin/guncoin,Kogser/bitcoin,cdecker/bitcoin,gjhiggins/vcoincore,yenliangl/bitcoin,untrustbank/litecoin,thrasher-/litecoin,tjps/bitcoin,jnewbery/bitcoin,DigitalPandacoin/pandacoin,FeatherCoin/Feathercoin,rawodb/bitcoin,n1bor/bitcoin,anditto/bitcoin,domob1812/namecore,BTCGPU/BTCGPU,wellenreiter01/Feathercoin,mruddy/bitcoin,jamesob/bitcoin,sipsorcery/bitcoin,apoelstra/bitcoin,Xekyo/bitcoin,lbryio/lbrycrd,midnightmagic/bitcoin,ajtowns/bitcoin,fanquake/bitcoin,dscotese/bitcoin,prusnak/bitcoin,namecoin/namecore,jambolo/bitcoin,jtimon/bitcoin,nikkitan/bitcoin,Kogser/bitcoin,domob1812/bitcoin,jmcorgan/bitcoin,namecoin/namecore,mitchellcash/bitcoin,thrasher-/litecoin,jamesob/bitcoin,bitcoinsSG/bitcoin,DigitalPandacoin/pandacoin,bitcoinsSG/bitcoin,mruddy/bitcoin,GroestlCoin/GroestlCoin,afk11/bitcoin,domob1812/bitcoin,joshrabinowitz/bitcoin,rnicoll/bitcoin,bespike/litecoin,jmcorgan/bitcoin,pstratem/bitcoin,jamesob/bitcoin,sebrandon1/bitcoin,pataquets/namecoin-core,r8921039/bitcoin,wellenreiter01/Feathercoin,Flowdalic/bitcoin,ElementsProject/elements,Kogser/bitcoin,apoelstra/bitcoin,Kogser/bitcoin,yenliangl/bitcoin,instagibbs/bitcoin,Flowdalic/bitcoin,prusnak/bitcoin,practicalswift/bitcoin,domob1812/huntercore,EthanHeilman/bitcoin,ajtowns/bitcoin,kallewoof/bitcoin,tecnovert/particl-core,BTCGPU/BTCGPU,GroestlCoin/GroestlCoin,ajtowns/bitcoin,CryptArc/bitcoin,domob1812/huntercore,jambolo/bitcoin,yenliangl/bitcoin,ElementsProject/elements,FeatherCoin/Feathercoin,fanquake/bitcoin,namecoin/namecoin-core,Christewart/bitcoin,pataquets/namecoin-core,kallewoof/bitcoin,GroestlCoin/GroestlCoin,jtimon/bitcoin,Kogser/bitcoin,FeatherCoin/Feathercoin,monacoinproject/monacoin,ajtowns/bitcoin,mitchellcash/bitcoin,droark/bitcoin,pataquets/namecoin-core,qtumproject/qtum,lbryio/lbrycrd,litecoin-project/litecoin,dscotese/bitcoin,Xekyo/bitcoin,Christewart/bitcoin,bitcoinsSG/bitcoin,kazcw/bitcoin,joshrabinowitz/bitcoin,untrustbank/litecoin,apoelstra/bitcoin,rnicoll/dogecoin,Xekyo/bitcoin,andreaskern/bitcoin,instagibbs/bitcoin,ElementsProject/elements,ahmedbodi/vertcoin,sipsorcery/bitcoin,vmp32k/litecoin,bitcoin/bitcoin,instagibbs/bitcoin,midnightmagic/bitcoin,ahmedbodi/vertcoin