Skip to content

Commit

Permalink
ResourceBase use OpenAPI::Document#operations for operations
Browse files Browse the repository at this point in the history
  • Loading branch information
notEthan committed Dec 4, 2024
1 parent d5f2879 commit 378710c
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions lib/scorpio/resource_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,7 @@ def api_method_name_by_operation(operation)
end

def update_class_and_instance_api_methods
openapi_document.paths.each do |path, path_item|
path_item.each do |http_method, operation|
next unless operation.is_a?(Scorpio::OpenAPI::Operation)
openapi_document.operations.each do |operation|
method_name = api_method_name_by_operation(operation)
if method_name
# class method
Expand All @@ -261,7 +259,6 @@ def update_class_and_instance_api_methods
end
end
end
end
end
end

Expand Down

0 comments on commit 378710c

Please sign in to comment.