Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 6db1b561f0 | |||
| 4256398cca |
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "stapler"
|
name = "stapler"
|
||||||
version = "1.2.0"
|
version = "1.2.1"
|
||||||
description = "Static pages as simple as a gzip file"
|
description = "Static pages as simple as a gzip file"
|
||||||
requires-python = ">=3.14"
|
requires-python = ">=3.14"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
|||||||
@@ -496,6 +496,7 @@ class RequestHandler(http.server.SimpleHTTPRequestHandler, BaseHandler):
|
|||||||
if (
|
if (
|
||||||
page.spa is not None
|
page.spa is not None
|
||||||
and not (self.root_path / pathlib.Path(path[1:])).is_file()
|
and not (self.root_path / pathlib.Path(path[1:])).is_file()
|
||||||
|
and not (self.root_path / pathlib.Path(path[1:]) / "index.html").is_file()
|
||||||
):
|
):
|
||||||
path = f"/{page.path}/{page.spa}"
|
path = f"/{page.path}/{page.spa}"
|
||||||
return super().translate_path(path)
|
return super().translate_path(path)
|
||||||
|
|||||||
Reference in New Issue
Block a user