<?php declare(strict_types=1);

namespace FilipSedivy\EET\Utils;

class Format
{
    public static function BKB($code): string
    {
        $r = '';
        for ($i = 0; $i < 40; $i++) {
            if ($i % 8 === 0 && $i !== 0) {
                $r .= '-';
            }
            $r .= $code[$i];
        }
        return $r;
    }
}
<?php declare(strict_types=1);

namespace FilipSedivy\EET\Utils;

class Format
{
    public static function BKB(string $code): string
    {
        $r = '';

        for ($i = 0; $i < 40; $i++) {
            if ($i % 8 === 0 && $i !== 0) {
                $r .= '-';
            }

            $r .= $code[$i];
        }

        return $r;
    }
}

Implement PHP 7.x and refactoring by PHPCS
:pencil2: Implement PHP 7.x and refactoring by PHPCS
