This commit is contained in:
Vlad Stan 2024-11-06 11:50:21 +02:00 committed by GitHub
parent 2020bd9838
commit de7fe059b8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
52 changed files with 6684 additions and 3120 deletions

View file

@ -1,13 +1,8 @@
import json
from http import HTTPStatus
from fastapi import Depends, Query, Request
from fastapi import Depends, Request
from fastapi.templating import Jinja2Templates
from loguru import logger
from starlette.responses import HTMLResponse
from lnbits.core.models import User
from lnbits.decorators import check_user_exists
from starlette.responses import HTMLResponse
from . import nostrmarket_ext, nostrmarket_renderer
@ -18,7 +13,7 @@ templates = Jinja2Templates(directory="templates")
async def index(request: Request, user: User = Depends(check_user_exists)):
return nostrmarket_renderer().TemplateResponse(
"nostrmarket/index.html",
{"request": request, "user": user.dict()},
{"request": request, "user": user.json()},
)