src/Utils/HelperSameWith.php
private static function get_sameWith_value($dio, $rules)
    {
        $sub_name = $rules['sameWith'];
        if ($rules instanceof Rules) {
            $sub_filter = clone $rules;
        } else {
            $sub_filter = $rules;
        }
        $sub_filter['sameWith'] = false;
        $sub_filter['required'] = false;
        $value                  = $dio->find($sub_name, $sub_filter);
        $value                  = $dio->verify->is($value, $sub_filter);

        return $value;
    }
private static function get_sameWith_value($dio, $rules)
    {
        $sub_name = $rules['sameWith'];
        if ($rules instanceof Rules) {
            $sub_filter = clone $rules;
        } else {
            $sub_filter = $rules;
        }
        $sub_filter['sameWith'] = false;
        $sub_filter['required'] = false;
        $value                  = $dio->find($sub_name, $sub_filter);
        $value                  = $dio->verify->is($value, $sub_filter);

        return $value;
    }
private static function get_sameWith_value ( $ dio , $ rules ) { $ sub_name = $ rules [ 'sameWith' ] ; if ( $ rules instanceof Rules ) { $ sub_filter = clone $ rules ; } else { $ sub_filter = $ rules ; } $ sub_filter [ 'sameWith' ] = false ; $ sub_filter [ 'required' ] = false ; $ value = $ dio -> find ( $ sub_name , $ sub_filter ) ; $ value = $ dio -> verify -> is ( $ value , $ sub_filter ) ; return $ value ; }
find the same with value.

@param Dio         $dio
@param array|Rules $rules
@return mixed
find the same with value .