Exception: Icons::LibraryNotFound

Inherits:
StandardError
  • Object
show all
Defined in:
lib/icons/errors.rb

Instance Method Summary collapse

Constructor Details

#initialize(library_name) ⇒ LibraryNotFound

Returns a new instance of LibraryNotFound.



15
16
17
18
19
20
21
22
# File 'lib/icons/errors.rb', line 15

def initialize(library_name)
  if library_name.empty?
    libraries = Icons.libraries.keys.join(", ")
    super("No libraries were specified. Please choose from: #{libraries}")
  else
    super("The library `#{library_name}` is not available. Please check the library name and try again.")
  end
end