Skip to content

Commit

Permalink
Add explicit require for node_factory
Browse files Browse the repository at this point in the history
This resolves an error that is caused by the removal of `#sort`
from Dir.glob. Dir.glob produces a slightly different file ordering
without sort and thus causes the below missing constant error.

```
Failure/Error:
  def allow_extensions(regex: EXTENSION_REGEX, &block)
    @extension_regex = regex
    @allowed_extensions = block || true
  end

NameError:
  uninitialized constant Openapi3Parser::NodeFactory::ObjectFactory::Dsl::EXTENSION_REGEX

          def allow_extensions(regex: EXTENSION_REGEX, &block)
```
  • Loading branch information
kevindew committed Jan 9, 2025
1 parent 347a2b0 commit 9d3e063
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/openapi3_parser/node_factory/object_factory/dsl.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# frozen_string_literal: true

require "openapi3_parser/node_factory"
require "openapi3_parser/node_factory/object_factory/field_config"

module Openapi3Parser
Expand Down

0 comments on commit 9d3e063

Please sign in to comment.