Remove unused method and move variable initialization in init.cpp
This is a partial backport of core#18766
The pull request is mostly not applicable to Bitcoin ABC. The variable moved in init.cpp are just to keep close to the source material and make future backports easier to review.