Skip to content

Not correct error when use an argument in callback #137

@mmikhalko

Description

@mmikhalko

Description

If add not use argument to endpoint is returning incorrect response:

{"error":{"code":404,"message":"Endpoint has an invalid elementType"}}

Steps to reproduce

'api/articles' => function($someId) {
..
}

  1. Add code
  2. Make a request
  3. Check error message of response

Additional info

  • Craft version: 3.5.14
  • PHP version: 7.3.15
  • Database driver & version: MySQL 5.6.39
  • Plugins & versions:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions