Class: InlineSvg::FindsAssetPaths
- Inherits:
-
Object
- Object
- InlineSvg::FindsAssetPaths
- Defined in:
- lib/inline_svg/finds_asset_paths.rb
Class Method Summary collapse
Class Method Details
.by_filename(filename) ⇒ Object
3 4 5 6 |
# File 'lib/inline_svg/finds_asset_paths.rb', line 3 def self.by_filename(filename) asset = configured_asset_finder.find_asset(filename) asset.try(:pathname) || asset.try(:filename) end |
.configured_asset_finder ⇒ Object
8 9 10 |
# File 'lib/inline_svg/finds_asset_paths.rb', line 8 def self.configured_asset_finder Thread.current[:inline_svg_asset_finder] || InlineSvg.configuration.asset_finder end |