Revert "Renamed funtion file() to send_file() because file
is a reserved"
This reverts commit 4cf68a4e3d
.
This commit is contained in:
parent
8fe75ed63d
commit
0deecd6a4e
|
@ -153,7 +153,7 @@ def html(body, status=200, headers=None):
|
||||||
content_type="text/html; charset=utf-8")
|
content_type="text/html; charset=utf-8")
|
||||||
|
|
||||||
|
|
||||||
async def send_file(location, mime_type=None, headers=None):
|
async def file(location, mime_type=None, headers=None):
|
||||||
filename = path.split(location)[-1]
|
filename = path.split(location)[-1]
|
||||||
|
|
||||||
async with open_async(location, mode='rb') as _file:
|
async with open_async(location, mode='rb') as _file:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user