mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-27 03:07:14 +00:00
Rename 'data' to 'date_attributes'
Prevents ambiguity, since there is already a `date` property defined in the instance.
This commit is contained in:
parent
797aeb5074
commit
408cade21f
@ -45,10 +45,10 @@ module Octopress
|
|||||||
# Returns the date-specific liquid attributes
|
# Returns the date-specific liquid attributes
|
||||||
def liquid_date_attributes
|
def liquid_date_attributes
|
||||||
date_format = self.site.config['date_format']
|
date_format = self.site.config['date_format']
|
||||||
data = {}
|
date_attributes = {}
|
||||||
data['date_formatted'] = format_date(self.data['date'], date_format) if self.data.has_key?('date')
|
date_attributes['date_formatted'] = format_date(self.data['date'], date_format) if self.data.has_key?('date')
|
||||||
data['updated_formatted'] = format_date(self.data['updated'], date_format) if self.data.has_key?('updated')
|
date_attributes['updated_formatted'] = format_date(self.data['updated'], date_format) if self.data.has_key?('updated')
|
||||||
data
|
date_attributes
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user