Exception: Shrine::InvalidFile

Inherits:
Error
  • Object
show all
Defined in:
lib/shrine.rb

Overview

Raised when a file is not a valid IO.

Instance Method Summary collapse

Constructor Details

#initialize(io, missing_methods) ⇒ InvalidFile

Returns a new instance of InvalidFile.



22
23
24
# File 'lib/shrine.rb', line 22

def initialize(io, missing_methods)
  super "#{io.inspect} is not a valid IO object (it doesn't respond to #{missing_methods.map{|m, _|"##{m}"}.join(", ")})"
end