Skip to content

path is '/api/user/test/:all? not work #181

@makkalay

Description

@makkalay

Environment

Not work for /api/user/test/ and /api/user/test only /api/user/test/' when path is '/api/user/test/:all?

Reproduction

export default defineNitroPlugin((nitroApp) => {
  nitroApp.router.use('/api/user/test/:all?', defineEventHandler(async (event) => {
    return 'Not work for /api/user/test/ and /api/user/test only /api/user/test/<something>'
  }))
})

Describe the bug

not work always

Additional context

No response

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions