public static function isEqual(...$ruts)
    {
        // If the user passed down one single argument as an array, we will use
        // that and unwrap it.
        if (is_array($ruts[0]) && func_num_args() === 1) {
            $ruts = $ruts[0];
        }

        // First, restore the keys of the array.
        $ruts = array_values($ruts);

        // Clean every value
        foreach ($ruts as &$rut) {
            $rut = self::cleanRut($rut);
        }

        // To see if all the ruts are equal we will remove the duplicates values.
        // Doing this should reduce the array to only 1 non-empty item, which
        // means that all the ruts are equal. Otherwise, they're not equal.
        return count($ruts = array_unique($ruts)) === 1 && !empty($ruts[0]);
    }
public static function isEqual(...$ruts)
    {
        // If the user passed down one single argument as an array, we will use
        // that and unwrap it.
        if (is_array($ruts[0]) && func_num_args() === 1) {
            $ruts = $ruts[0];
        }

        // First, restore the keys of the array.
        $ruts = array_values($ruts);

        // Clean every value
        foreach ($ruts as &$rut) {
            $rut = self::cleanRut($rut);
        }

        // To see if all the ruts are equal we will remove the duplicates values.
        // Doing this should reduce the array to only 1 non-empty item, which
        // means that all the ruts are equal. Otherwise, they're not equal.
        return count($ruts = array_unique($ruts)) === 1 && !empty($ruts[0]);
    }
public static function isEqual ( ... $ ruts ) { // If the user passed down one single argument as an array, we will use // that and unwrap it. if ( is_array ( $ ruts [ 0 ] ) && func_num_args ( ) === 1 ) { $ ruts = $ ruts [ 0 ] ; } // First, restore the keys of the array. $ ruts = array_values ( $ ruts ) ; // Clean every value foreach ( $ ruts as & $ rut ) { $ rut = self :: cleanRut ( $ rut ) ; } // To see if all the ruts are equal we will remove the duplicates values. // Doing this should reduce the array to only 1 non-empty item, which // means that all the ruts are equal. Otherwise, they're not equal. return count ( $ ruts = array_unique ( $ ruts ) ) === 1 && ! empty ( $ ruts [ 0 ] ) ; }
Return if two or more RUTs are equal

@param array $ruts
@return bool
Return if two or more RUTs are equal