Skip to content
Permalink
Browse files

fix obvious brainfarts

  • Loading branch information
ralsina committed May 4, 2017
1 parent d041bfa commit 813b330eebc31074d05d1c76f10c974539d36dcf
Showing with 3 additions and 3 deletions.
  1. +2 −2 nikola/plugins/compile/rest/__init__.py
  2. +1 −1 nikola/shortcodes.py
@@ -82,7 +82,7 @@ def compile_string(self, data, source_path=None, is_two_file=True, post=None, la
}

from nikola import shortcodes as sc
new_data, shortcodes = sc._extract_shortcodes(data)
new_data, shortcodes = sc.extract_shortcodes(data)
output, error_level, deps = rst2html(
new_data, settings_overrides=settings_overrides, logger=self.logger, source_path=source_path, l_add_ln=add_ln, transforms=self.site.rst_transforms,
no_title_transform=self.site.config.get('NO_DOCUTILS_TITLE_TRANSFORM', False))
@@ -91,7 +91,7 @@ def compile_string(self, data, source_path=None, is_two_file=True, post=None, la
# Original issue: empty files. `output` became a bytestring.
output = output.decode('utf-8')

output, shortcode_deps = self.site.apply_shortcodes2(output, shortcodes, filename=source_path, with_dependencies=True, extra_context=dict(post=post))
output, shortcode_deps = self.site.apply_shortcodes_uuid(output, shortcodes, filename=source_path, with_dependencies=True, extra_context=dict(post=post))
return output, error_level, deps, shortcode_deps

# TODO remove in v8
@@ -209,7 +209,7 @@ def _parse_shortcode_args(data, start, shortcode_name, start_pos):
raise ParsingError("Shortcode '{0}' starting at {1} is not terminated correctly with '%}}}}'!".format(shortcode_name, _format_position(data, start_pos)))


def _extract_shortcodes(data):
def extract_shortcodes(data):
"""
Returns data, shortcodes:

0 comments on commit 813b330

Please sign in to comment.
You can’t perform that action at this time.