Class: Refinery::SitemapController

Inherits:
FastController
  • Object
show all
Defined in:
app/controllers/refinery/sitemap_controller.rb

Instance Method Summary collapse

Methods inherited from FastController

#message, #wymiframe

Instance Method Details

#indexObject



5
6
7
8
9
10
11
12
13
14
15
16
17
# File 'app/controllers/refinery/sitemap_controller.rb', line 5

def index
  headers['Content-Type'] = 'application/xml'

  respond_to do |format|
    format.xml do
      @locales = if defined?(::Refinery::I18n) && ::Refinery::I18n.enabled?
                   ::Refinery::I18n.frontend_locales
                 else
                   [::I18n.locale]
                 end
    end
  end
end