lib/includes/SimpleCacheWithBagOStuff.php
Method decode
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function decode( string $string, array $loggingContext ): ?array {
$result = json_decode( $string );
if ( !is_array( $result ) || count( $result ) !== 3 ) {
$this->logger->alert( 'Unknown or invalid cache format', $loggingContext + [
Avoid too many return
statements within this method. Open
Open
return [ 'signatureToCheck' => $signatureToCheck, 'data' => $data ];