You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix static location in index when prefix is used (#1662)
When the prefix is used (e.g. not /), the links generated in the
index page are wrong. In this patch the relative path is correctly
calculated by the pathlib module and a absolute url is used as link
in the index page.
The original bug can be demonstrated with following example:
---
import pathlib
from aiohttp import web
app = web.Application()
app.router.add_static('/static', pathlib.Path(__file__).parent,
show_index=True)
web.run_app(app)
---
0 commit comments