From f128ed5b1fc1472e5939a78099ebecd892deef1f Mon Sep 17 00:00:00 2001 From: Joar Wandborg Date: Fri, 3 Nov 2017 14:37:01 +0100 Subject: [PATCH] Set threshold to 1MiB instead of 0.97MiB Reference: https://en.wikipedia.org/wiki/Mebibyte#Definition --- sanic/static.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sanic/static.py b/sanic/static.py index 0798e2fe..f2d02ab0 100644 --- a/sanic/static.py +++ b/sanic/static.py @@ -104,7 +104,7 @@ def register(app, uri, file_or_directory, pattern, if isinstance(stream_large_files, int): threshold = stream_large_files else: - threshold = 1024 * 1000 + threshold = 1024 * 1024 if not stats: stats = await stat(file_path)