public function detectVersion(string $useragent, array $searches = [], string $default = '0'): VersionInterface
    {
        $modifiers = [
            ['\/', ''],
            ['\(', '\)'],
            [' ', ';'],
            [' ', ''],
            ['', ''],
            [' \(', ';'],
        ];

        $version = $default;

        if (false !== mb_strpos($useragent, '%')) {
            $useragent = urldecode($useragent);
        }

        foreach ($searches as $search) {
            if (!is_string($search)) {
                continue;
            }

            if (false !== mb_strpos($search, '%')) {
                $search = urldecode($search);
            }

            foreach ($modifiers as $modifier) {
                $compareString = '/' . $search . $modifier[0] . '(\d+[\d._\-+ abcdehlprstv]*)' . $modifier[1] . '/i';
                $matches       = [];
                $doMatch       = preg_match($compareString, $useragent, $matches);

                if ($doMatch) {
                    $version = mb_strtolower(str_replace('_', '.', $matches[1]));

                    break 2;
                }
            }
        }

        return $this->set($version);
    }