class Darkroom::MissingLibraryError
Error class used when a needed library cannot be loaded. See Asset#require_libs
.
Attributes
extension[R]
library[R]
need[R]
Public Class Methods
new(library, need, extension)
click to toggle source
Creates a new instance.
-
library
- Name of the library that's missing. -
need
- Reason the library is needed ('compile' or 'minify'). -
extension
- Extension of the type of asset that needs the library.
# File lib/darkroom/errors/missing_library_error.rb, line 17 def initialize(library, need, extension) @library = library @need = need @extension = extension end
Public Instance Methods
to_s()
click to toggle source
Returns a string representation of the error.
# File lib/darkroom/errors/missing_library_error.rb, line 26 def to_s "Cannot #{@need} #{@extension} file(s): #{@library} library not available [hint: try adding "\ "gem('#{@library}') to your Gemfile]" end