Move BetaFeatures check to hooks called later

The BetaFeatures check was breaking some api calls because it was being
done before the request was fully initialized.  Now we wait until the
last possible second to perform the BetaFeatures check and the user is
good and ready.

Requires I0a167faaa4166da381194c53373d82e038848924 in mediawiki core to
function for api requests.

Bug: 58380
Change-Id: I3d6f43846f8086d7aa41d2c43150a7fa8d612d59
Merge "Move BetaFeatures check to hooks called later"