Class: Maglev::FetchPage

Inherits:
Object
  • Object
show all
Includes:
Injectable
Defined in:
app/services/maglev/fetch_page.rb

Overview

Retrieve a page from a path and a locale (previously extracted by the ExtractLocale service)

Instance Method Summary collapse

Instance Method Details

#callObject



14
15
16
17
18
# File 'app/services/maglev/fetch_page.rb', line 14

def call
  page = fetch_page(path, locale)
  page = fetch_page(path, default_locale) if !page && fallback_to_default_locale
  page
end