Commit afd686a4 authored by Felix Hamme's avatar Felix Hamme
Browse files

backend: allow '/' in image names

parent 743bae9f
......@@ -10,7 +10,7 @@ from .cyberjudo import CyberJudo
def get_images_router(cyberjudo: CyberJudo, images_dir: str, cjc: CyberJudoCrypto):
router = APIRouter()
@router.get('/named-images/{name}', response_class=FileResponse,
@router.get('/named-images/{name:path}', response_class=FileResponse,
description='this directly returns an image (mime type depending on the file), if known')
def get_image_by_name(name: str):
if not cyberjudo.image_is_known(name):
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment