mail: Turn UserMailer::quotedPrintableCallback into an inline closure
[lhc/web/wiklou.git] / includes / mail / UserMailer.php
index 464e7b8..1c7fb98 100644 (file)
@@ -501,12 +501,12 @@ class UserMailer {
                }
                $out = "=?$charset?Q?";
                $out .= preg_replace_callback( "/([$replace])/",
-                       [ __CLASS__, 'quotedPrintableCallback' ], $string );
+                       function ( $matches ) {
+                               return sprintf( "=%02X", ord( $matches[1] ) );
+                       },
+                       $string
+               );
                $out .= '?=';
                return $out;
        }
-
-       protected static function quotedPrintableCallback( $matches ) {
-               return sprintf( "=%02X", ord( $matches[1] ) );
-       }
 }