Method: Common::Color#format_state

Defined in:
lib/common/color.rb

#format_state(state) ⇒ Object

Format the state.

Parameters:

  • state

    The state

Author:

  • tmarmin



238
239
240
241
242
243
244
245
246
247
# File 'lib/common/color.rb', line 238

def format_state(state)
  case which_color(state)
    when "green"
      return color_green(state)
    when "red"
      return color_red(state)
    else
      return color_yellow(state)
  end
end