MatthewMi11er/mi11er-library

View on GitHub
src/mi11er-library/Text/Formatters/TitleCaseFormatter.php

Summary

Maintainability
A
1 hr
Test Coverage

Consider simplifying this complex logical expression.
Open

        if ($offset > 0                                         && // We're not at the start.
            $matchEnd !== mb_strlen($this->title, 'UTF-8')      && // A single word title is not lower case.
            preg_match($this->smallWords, $matches[0])          && // Small words are lower case.
            $this->getChar($offset - 2) !== ':'                 && // Words after a colon are not lower case.
          ! preg_match('/[^\s-]/', $this->getChar($offset - 1)) &&
Severity: Major
Found in src/mi11er-library/Text/Formatters/TitleCaseFormatter.php - About 1 hr to fix

    There are no issues that match your filters.

    Category
    Status