lib/sapphire_bot.rb
# Converts boolean values to more appealing format.
# Possible modes: on, enabled.
Converts boolean values to more appealing format.
Possible modes: on, enabled.
Converts boolean values to more appealing format . Possible modes : on enabled .
def bool_to_words(bool, mode = :on)
    case mode
    when :on
      string_if_true = 'on'
      string_if_false = 'off'
    when :enabled
      string_if_true = 'enabled'
      string_if_false = 'disabled'
    else
      raise ArgumentError
    end
    return string_if_true if bool
    string_if_false
  end
def bool_to_words ( bool , mode = :on ) case mode when :on string_if_true = 'on' string_if_false = 'off' when :enabled string_if_true = 'enabled' string_if_false = 'disabled' else raise ArgumentError end return string_if_true if bool string_if_false end
Converts boolean values to more appealing format.
Converts boolean values to more appealing format .
bool
<not_specific>
mode
<not_specific>