Mercurial > piecrust2
diff piecrust/data/assetor.py @ 33:62c7a97c8340
Get the un-paginated URL of a page early and pass that around.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Tue, 19 Aug 2014 15:36:28 -0700 |
parents | 43091c9837bf |
children | 0445a2232de7 |
line wrap: on
line diff
--- a/piecrust/data/assetor.py Tue Aug 19 14:30:19 2014 -0700 +++ b/piecrust/data/assetor.py Tue Aug 19 15:36:28 2014 -0700 @@ -1,4 +1,3 @@ -import re import os import os.path import logging @@ -16,15 +15,11 @@ base_url_format = app.env.base_asset_url_format rel_assets_path = rel_assets_path.replace('\\', '/') - # Remove any extension or pagination suffix from the URL, since - # we'll be copying assets into the 1st sub-page's folder. + # Remove any extension since we'll be copying assets into the 1st + # sub-page's folder. pretty = app.config.get('site/pretty_urls') if not pretty: uri, _ = os.path.splitext(uri) - pgn_suffix_re = app.config.get('__cache/pagination_suffix_re') - m = re.search(pgn_suffix_re, uri) - if m: - uri = uri[:m.start():] base_url = multi_replace( base_url_format,