From ab44afa0008945d04a6ecdc2a64733589105546b Mon Sep 17 00:00:00 2001 From: valentinkolb Date: Wed, 27 Mar 2024 20:07:30 +0100 Subject: [PATCH] feat(qrApi): added attachment header added new header to api response to that the qr code can be downloaded --- qrApi/main.go | 1 + 1 file changed, 1 insertion(+) diff --git a/qrApi/main.go b/qrApi/main.go index dd3a5f1..4970be0 100644 --- a/qrApi/main.go +++ b/qrApi/main.go @@ -102,6 +102,7 @@ func InitQRApi(app *pocketbase.PocketBase, e *core.ServeEvent) error { } // return qr code as svg + c.Response().Header().Set("Content-disposition", "attachment; filename=QR.svg") return c.Stream(200, "image/svg+xml", io.Reader(&buffer)) }, apis.ActivityLogger(app))