refactor: Combine GetWalletForJSONRPCRequest and EnsureWalletIsAvailable functions
Summary:
This simplifies control flow and also helps get rid of the ::vpwallets
variable, because EnsureWalletIsAvailable doesn't have access to the request
context.
This is a backport of core#19100
Test Plan: ninja all check-all
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Subscribers: deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D9452