Permalink
Browse files

[svn] Updated template controller default to just render the template…

… rather than attempting to use pkg_resources to stat the file.

--HG--
branch : trunk
  • Loading branch information...
1 parent 013e247 commit 9bd910d12c79d38a12d7663feca2a38e148d8576 bbangert committed Jun 5, 2006
Showing with 1 addition and 5 deletions.
  1. +1 −5 pylons/templates/paster_template/+package+/controllers/template.py_tmpl
@@ -7,11 +7,7 @@ class TemplateController(BaseController):
file to serve. It could be used for example to display a template::
def view(self, url):
- from pkg_resources import resource_exists
- if resource_exists('${package}', url+'.myt'):
- m.subexec(url+'.myt')
- else:
- m.abort(404, "File not found")
+ return render_response(url+'.myt')
The default is just to abort the request with a 404 File not found
status message.

0 comments on commit 9bd910d

Please sign in to comment.