Module: Para::Component::Importable
Instance Method Summary collapse
- #importable? ⇒ Boolean
-
#importers ⇒ Object
TODO : Move :configuration column store to JSON instead of HStore which handles more data types and will help us avoid eval here.
Instance Method Details
#importable? ⇒ Boolean
10 11 12 |
# File 'lib/para/component/importable.rb', line 10 def importable? @importable ||= importers.length > 0 end |
#importers ⇒ Object
TODO : Move :configuration column store to JSON instead of HStore which handles more data types and will help us avoid eval here
16 17 18 19 20 21 22 |
# File 'lib/para/component/importable.rb', line 16 def importers @importers ||= if (importers = configuration['importers'].presence) eval(importers).map(&:constantize) else [] end end |