Navigation Menu

Skip to content

Commit

Permalink
rest too
Browse files Browse the repository at this point in the history
  • Loading branch information
ralsina committed Jun 9, 2015
1 parent 8a522c8 commit 22493dc
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions nikola/plugins/compile/rest/__init__.py
Expand Up @@ -64,15 +64,8 @@ def compile_html_string(self, data, source_path=None, is_two_file=True):
"""Compile reSt into HTML strings."""
add_ln = 0
if not is_two_file:
spl = re.split('(\n\n|\r\n\r\n)', data, maxsplit=1)
data = spl[-1]
if len(spl) != 1:
# If errors occur, this will be added to the line
# number reported by docutils so the line number
# matches the actual line number (off by 7 with default
# metadata, could be more or less depending on the post
# author).
add_ln = len(spl[0].splitlines()) + 1
m_data, data = self.split_metadata(data)
add_ln = len(m_data.splitlines()) + 1

default_template_path = os.path.join(os.path.dirname(__file__), 'template.txt')
output, error_level, deps = rst2html(
Expand Down

0 comments on commit 22493dc

Please sign in to comment.