WordPress at a glance
function is not described

PHPMailer\PHPMailer

PHPMailer::normalizeBreaks() public WP 1.0

Normalize line breaks in a string. Converts UNIX LF, Mac CR and Windows CRLF line breaks into a single line break format. Defaults to CRLF (for message bodies) and preserves consecutive breaks.

{} It's a method of the class: PHPMailer{}

No Hooks.

Return

String.

Usage

$result = PHPMailer::normalizeBreaks( $text, $breaktype );
$text(string) (required)
-
$breaktype(string)
What kind of line break to use; defaults to static::$LE

Code of PHPMailer::normalizeBreaks() WP 5.7.2

<?php
public static function normalizeBreaks($text, $breaktype = null)
{
    if (null === $breaktype) {
        $breaktype = static::$LE;
    }
    //Normalise to \n
    $text = str_replace([self::CRLF, "\r"], "\n", $text);
    //Now convert LE as needed
    if ("\n" !== $breaktype) {
        $text = str_replace("\n", $breaktype, $text);
    }

    return $text;
}