Skip to content

Plugin does not work with strict mode #51

@amarkezic

Description

@amarkezic

Describe the bug
With ajv option set to strict mode the ajv-merge-patch package does not work. I receive the error:
strict mode: required property "value" is not defined at "#/properties/with/items/anyOf/0" (strictRequired)

To Reproduce
Steps to reproduce the behavior:

  1. Set ajv schema option { strict: true }
  2. Register the plugin
  3. Run fastify
  4. See error

Expected behavior
Package should work even with strict mode on

Do you have a proposed solution?
In this line a property is required which is not defined, after removing it locally everything worked as expected.

"required": [ "value" ]

Additional context and screenshots
Add any other context about the problem, and screenshots if applicable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions