Exception: Clearbooks::ClearbooksfileNotFound

Inherits:
ClearbooksError show all
Defined in:
lib/clearbooks/error/errors.rb

Instance Method Summary collapse

Methods inherited from ClearbooksError

status_code

Constructor Details

#initialize(filepath) ⇒ ClearbooksfileNotFound

Returns a new instance of ClearbooksfileNotFound.

Parameters:

  • filepath (#to_s)

    the path where a Clearbooksfile was not found



32
33
34
# File 'lib/clearbooks/error/errors.rb', line 32

def initialize(filepath)
  @filepath = File.dirname(File.expand_path(filepath)) rescue filepath
end

Instance Method Details

#to_sObject



36
37
38
# File 'lib/clearbooks/error/errors.rb', line 36

def to_s
  "No Clearbooksfile or Clearbooksfile.lock found at '#{@filepath}'!"
end