create a liquid drop for site (include a method to get the home page)
This commit is contained in:
parent
d632a5363c
commit
a03b631a71
@ -75,7 +75,7 @@ class Page
|
||||
self.cache_strategy != 'none'
|
||||
end
|
||||
|
||||
def to_liquid(options = {})
|
||||
def to_liquid
|
||||
Locomotive::Liquid::Drops::Page.new(self)
|
||||
end
|
||||
|
||||
|
@ -57,6 +57,10 @@ class Site
|
||||
((self.domains || []) + ["#{self.subdomain}.#{Locomotive.config.default_domain}"]).uniq
|
||||
end
|
||||
|
||||
def to_liquid
|
||||
Locomotive::Liquid::Drops::Site.new(self)
|
||||
end
|
||||
|
||||
protected
|
||||
|
||||
def domains_must_be_valid_and_unique
|
||||
|
@ -3,8 +3,6 @@ module Locomotive
|
||||
module Drops
|
||||
class Page < Base
|
||||
|
||||
# liquid_attributes << :title << :slug
|
||||
|
||||
def title
|
||||
@source.templatized? ? @context['content_instance'].highlighted_field_value : @source.title
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user