This method has worked successfully for me before.
In fact I just did the good wifi check, I had >70% charge, plug in to charger, wait a little, reboot while still charging, wait a little, I think I started the see the folders start repopulating quite quickly, un-pluged charger, full syncing continued slowly for quite a while.
This was an enormous surprise to me, things returned from long ago … and was more or less effortless!