Return to Snippet

Revision: 3526
at August 7, 2007 08:57 by capitalist


Updated Code
def dev_mode?
    ENV['RAILS_ENV'] == 'development' && request.host == '127.0.0.1'
  end

Revision: 3525
at August 7, 2007 08:56 by capitalist


Initial Code
  def dev_mode?
    ENV['RAILS_ENV'] == 'development' && request.host == '127.0.0.1'
  end

Initial URL


Initial Description
override the boolean expression with your own conditions.

Initial Title
Rails helper to check if you're in dev mode.

Initial Tags
rails

Initial Language
Rails