src/Model/SiteLog.php
protected function countLines($file)
    {
        $fh    = fopen($file, 'rb');
        $lines = 0;

        while (!feof($fh)) {

            $line = fgets($fh);

            if (empty($line)) {

                continue;
            }

            $lines++;
        }

        fclose($fh);

        //  subtract 1, account for the opening <?php line
        return $lines - 1;
    }
protected function countLines($file)
    {
        $fh    = fopen($file, 'rb');
        $lines = 0;

        while (!feof($fh)) {

            $line = fgets($fh);

            if (empty($line)) {

                continue;
            }

            $lines++;
        }

        fclose($fh);

        //  subtract 1, account for the opening <?php line
        return $lines - 1;
    }
--------------------------------------------------------------------------