Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails without version? #2

Open
OlegKunitsyn opened this issue Mar 3, 2024 · 0 comments
Open

Fails without version? #2

OlegKunitsyn opened this issue Mar 3, 2024 · 0 comments

Comments

@OlegKunitsyn
Copy link

    App\JsonRpcController\:
        resource: '../src/JsonRpcController/{*Method.php}'
        tags:
            - { name: ov.rpc.method, namespace: App\JsonRpcController\ }
<?php

declare(strict_types=1);

namespace App\JsonRpcController;

use App\Dto\EchoDto;
use OV\JsonRPCAPIBundle\Core\Annotation\JsonRPCAPI;

#[JsonRPCAPI(methodName: 'productEcho', type: 'POST')]
class JsonRpcProductEchoMethod
{
    public function call(EchoDto $dto): EchoDto
    {
        return $dto;
    }
}

{"jsonrpc":"2.0","error":{"code":0,"message":"App\\JsonRpcController\\JsonRpcProductEchoMethod::call(): Argument #1 ($dto) must be of type App\\Dto\\EchoDto, null given, called in \/vendor\/otezvikentiy\/json-rpc-api\/src\/Controller\/ApiController.php on line 133"},"id":"1"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant