Sha256: 4edcbb6d8b0a929bf5c8f9f3fac07247a1033ce9a6dbce0914dfc99691de6c0c
Contents?: true
Size: 346 Bytes
Versions: 7
Compression:
Stored size: 346 Bytes
Contents
module SharingTags class AssetFile class FileNotFound < IOError; end UNREADABLE_PATH = '' def self.named(filename) asset_path = FindsAssetPaths.by_filename(filename) File.read(asset_path || UNREADABLE_PATH) rescue Errno::ENOENT => e raise FileNotFound, "Asset not found: #{asset_path}: #{e}" end end end
Version data entries
7 entries across 7 versions & 1 rubygems