Code Duplication    Length = 30-30 lines in 2 locations

manager/includes/controls/phpmailer/PHPMailer.php 1 location

@@ 800-829 (lines=30) @@
797
798
            return;
799
        }
800
        switch ($this->Debugoutput) {
801
            case 'error_log':
802
                //Don't output, just log
803
                error_log($str);
804
                break;
805
            case 'html':
806
                //Cleans up output a bit for a better looking, HTML-safe output
807
                echo htmlentities(
808
                    preg_replace('/[\r\n]+/', '', $str),
809
                    ENT_QUOTES,
810
                    'UTF-8'
811
                ), "<br>\n";
812
                break;
813
            case 'echo':
814
            default:
815
                //Normalize line breaks
816
                $str = preg_replace('/\r\n|\r/ms', "\n", $str);
817
                echo gmdate('Y-m-d H:i:s'),
818
                "\t",
819
                    //Trim trailing space
820
                trim(
821
                //Indent for readability, except for trailing break
822
                    str_replace(
823
                        "\n",
824
                        "\n                   \t                  ",
825
                        trim($str)
826
                    )
827
                ),
828
                "\n";
829
        }
830
    }
831
832
    /**

manager/includes/controls/phpmailer/SMTP.php 1 location

@@ 246-275 (lines=30) @@
243
244
            return;
245
        }
246
        switch ($this->Debugoutput) {
247
            case 'error_log':
248
                //Don't output, just log
249
                error_log($str);
250
                break;
251
            case 'html':
252
                //Cleans up output a bit for a better looking, HTML-safe output
253
                echo gmdate('Y-m-d H:i:s'), ' ', htmlentities(
254
                    preg_replace('/[\r\n]+/', '', $str),
255
                    ENT_QUOTES,
256
                    'UTF-8'
257
                ), "<br>\n";
258
                break;
259
            case 'echo':
260
            default:
261
                //Normalize line breaks
262
                $str = preg_replace('/\r\n|\r/ms', "\n", $str);
263
                echo gmdate('Y-m-d H:i:s'),
264
                "\t",
265
                    //Trim trailing space
266
                trim(
267
                //Indent for readability, except for trailing break
268
                    str_replace(
269
                        "\n",
270
                        "\n                   \t                  ",
271
                        trim($str)
272
                    )
273
                ),
274
                "\n";
275
        }
276
    }
277
278
    /**