Merge pull request #4786 from jekyll/convertible-use-doc-frontmatter-regexp
Merge pull request 4786
This commit is contained in:
commit
f922e8994a
|
@ -41,7 +41,7 @@ module Jekyll
|
|||
begin
|
||||
self.content = File.read(site.in_source_dir(base, name),
|
||||
Utils.merged_file_read_opts(site, opts))
|
||||
if content =~ /\A(---\s*\n.*?\n?)^((---|\.\.\.)\s*$\n?)/m
|
||||
if content =~ Document::YAML_FRONT_MATTER_REGEXP
|
||||
self.content = $POSTMATCH
|
||||
self.data = SafeYAML.load(Regexp.last_match(1))
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue