module Lingo24 # Custom +Exception+ class for errors returned from the Lingo24 Translation APIs. class Exception < :: StandardError attr_accessor :code # Creates a new +Language+. # # Parameters: # code - a string containing the status code of the message. # msg - a string containing the exception message. def initialize(code, msg) @code = code @message = msg end # Overrides default +message+ to return the exception's message. def message @message end end end