Skip to content

Support bodyparser's 'type' option as function #5

@Equals182

Description

@Equals182

This module uses bodyparser.text() to parse body as text and passes options object to configure it.

As you can see here, bodyparser accepts options.type options as function, which allows user to control type matching precisely.

Unfortunately, in body-parser-xml there is a line where it check if passed options.type is not an array and convert it into array thus breaking default bodyparser.text()'s ability to use user's function, because that function checks if passed 'type' option is a function

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions