consider a case of "site" is unavailable in Convertible
This commit is contained in:
parent
f4c2383d3c
commit
4cb24f4b87
|
@ -28,7 +28,8 @@ module Jekyll
|
|||
# Returns nothing.
|
||||
def read_yaml(base, name)
|
||||
begin
|
||||
self.content = File.read(File.join(base, name), self.site.file_read_opts)
|
||||
opts = self.site ? self.site.file_read_opts : {}
|
||||
self.content = File.read(File.join(base, name), opts)
|
||||
|
||||
if self.content =~ /\A(---\s*\n.*?\n?)^(---\s*$\n?)/m
|
||||
self.content = $POSTMATCH
|
||||
|
|
Loading…
Reference in New Issue