public static function make(...$ruts)
    {
        // Reset the array index to a sequential one.
        $ruts = array_values($ruts);

        // First check if the dev passed one single array instead multiple $ruts.
        // If that's the case, we will unwrap the array and use that. Otherwise,
        // we will use all the arguments as they come and transform each one.
        if (is_array($ruts[0]) && func_num_args() === 1) {
            $ruts = $ruts[0];
        }

        foreach ($ruts as &$rut) {
            $rut = new static($rut);
        }

        // If the resulting array is more than one, return all the array, otherwise
        // unpack the single value. This allows to match the arguments.
        return count($ruts) === 1 ? $ruts[0] : $ruts;
    }
public static function make(...$ruts)
    {
        // Reset the array index to a sequential one.
        $ruts = array_values($ruts);

        // First check if the dev passed one single array instead multiple $ruts.
        // If that's the case, we will unwrap the array and use that. Otherwise,
        // we will use all the arguments as they come and transform each one.
        if (is_array($ruts[0]) && func_num_args() === 1) {
            $ruts = $ruts[0];
        }

        foreach ($ruts as &$rut) {
            $rut = new static($rut);
        }

        // If the resulting array is more than one, return all the array, otherwise
        // unpack the single value. This allows to match the arguments.
        return count($ruts) === 1 ? $ruts[0] : $ruts;
    }
public static function make ( ... $ ruts ) { // Reset the array index to a sequential one. $ ruts = array_values ( $ ruts ) ; // First check if the dev passed one single array instead multiple $ruts. // If that's the case, we will unwrap the array and use that. Otherwise, // we will use all the arguments as they come and transform each one. if ( is_array ( $ ruts [ 0 ] ) && func_num_args ( ) === 1 ) { $ ruts = $ ruts [ 0 ] ; } foreach ( $ ruts as & $ rut ) { $ rut = new static ( $ rut ) ; } // If the resulting array is more than one, return all the array, otherwise // unpack the single value. This allows to match the arguments. return count ( $ ruts ) === 1 ? $ ruts [ 0 ] : $ ruts ; }
Creates a new Rut instance

@param mixed ...$ruts
@return Rut|array
@throws InvalidRutException
Creates a new Rut instance