Class: Iron::SDK
- Inherits:
-
Object
- Object
- Iron::SDK
- Defined in:
- lib/iron/sdk.rb
Class Method Summary collapse
Class Method Details
.method_missing(method) ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/iron/sdk.rb', line 3 def self.method_missing(method) content_type_handle = method.to_s content_type = Iron::ContentType.find_by(handle: content_type_handle) return super unless content_type.present? return content_type.entry if content_type.single? content_type.entries end |
.respond_to_missing?(method, include_private = false) ⇒ Boolean
14 15 16 17 |
# File 'lib/iron/sdk.rb', line 14 def self.respond_to_missing?(method, include_private = false) content_type_handle = method.to_s Iron::ContentType.exists?(handle: content_type_handle) || super end |