From 4c66cb18544244bc5431e7ed6759b06e7618575a Mon Sep 17 00:00:00 2001 From: messense Date: Thu, 13 Apr 2017 12:11:38 +0800 Subject: [PATCH] Fix static files router --- sanic/app.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sanic/app.py b/sanic/app.py index d2894ff2..0ff98423 100644 --- a/sanic/app.py +++ b/sanic/app.py @@ -288,7 +288,7 @@ class Sanic: attach_to=middleware_or_request) # Static Files - def static(self, uri, file_or_directory, pattern='.+', + def static(self, uri, file_or_directory, pattern=r'/?.+', use_modified_since=True, use_content_range=False): """Register a root to serve files from. The input can either be a file or a directory. See