diff options
author | Chris Jerdonek <chris.jerdonek@gmail.com> | 2012-05-03 13:46:46 -0700 |
---|---|---|
committer | Chris Jerdonek <chris.jerdonek@gmail.com> | 2012-05-04 05:38:19 -0700 |
commit | 69c44762bbfbdbcf5c85e534af691f03150a82c7 (patch) | |
tree | c904f092c985a1b8170a26747309faa1880973e3 /pystache/parser.py | |
parent | 170c65df0b0d4eed75997b2eee05dd755b301d3b (diff) | |
download | pystache-69c44762bbfbdbcf5c85e534af691f03150a82c7.tar.gz |
Moved the partial-loading code from the parser module to the renderengine module.
Diffstat (limited to 'pystache/parser.py')
-rw-r--r-- | pystache/parser.py | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/pystache/parser.py b/pystache/parser.py index 4e05f3b..5a56f4c 100644 --- a/pystache/parser.py +++ b/pystache/parser.py @@ -9,7 +9,6 @@ This module is only meant for internal use by the renderengine module. import re -from pystache.common import TemplateNotFoundError from pystache.parsed import ParsedTemplate @@ -216,15 +215,9 @@ class Parser(object): elif tag_type == '>': - try: - # TODO: make engine.load() and test it separately. - template = engine.load_partial(tag_key) - except TemplateNotFoundError: - template = u'' - + template = engine.read_partial(tag_key) # Indent before rendering. template = re.sub(NON_BLANK_RE, leading_whitespace + ur'\1', template) - func = engine._make_get_partial(template) else: |