Skip to content

Missing null guard causes "Cannot read properties of null (reading 'enum')"  #2959

Description

@anderaus

I believe a bug was introduced in #2934, see link below

Was the @ && null guard removed on purpose? I believe I'm seeing crashes when nimma hits a null node.

Originally posted by @anderaus in #2934

Bug can be reproduced using this input:

{
  "openapi": "3.0.2",
  "info": { "title": "Test", "version": "1.0" },
  "paths": {},
  "components": {
    "examples": {
      "test": {
        "value": {
          "foo": null
        }
      }
    }
  }
}

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