Fix performance error in OAuth class check.

I’ll buy a pint for the dev that describes this bug this fixes in the best detail.
Merge pull request #2241 from vanilla/hotfix/oauth-autoloader-performance

Fix performance error in OAuth class check.