Fixed robots.txt so that preview is not crawlable

This commit is contained in:
Godwin 2016-08-12 08:33:44 -07:00 committed by GitHub
parent aaaabb17c6
commit b89cad4ec4

View File

@ -90,8 +90,7 @@ class ApplicationController < LinguaFrancaApplicationController
end
def robots
robot = is_production? && !is_test_server? ? 'live' : 'dev'
render :text => File.read("config/robots-#{robot}.txt"), :content_type => 'text/plain'
render :text => File.read("config/robots-#{Rails.env.production? ? 'live' : 'dev'}.txt"), :content_type => 'text/plain'
end
def humans