Fix some PHP 8.1 "strlen(null)" exceptions in MediaWiki Auth provider

Aklapper requested to merge T343568php81MWOAuth into wmf/stable

Bug: T343568

Merge request reports