public static function camelCaseToUnderscore($string)
    {
        return Preg::replaceCallback(
            '/(^|[a-z0-9])([A-Z])/',
            static function (array $matches) {
                return strtolower('' !== $matches[1] ? $matches[1].'_'.$matches[2] : $matches[2]);
            },
            $string
        );
    }