From 684e3af3ef8291e30467ec89856a762c6a40c3b4 Mon Sep 17 00:00:00 2001 From: Gowtham M Date: Fri, 29 Aug 2025 11:56:01 +0530 Subject: [PATCH] image acces api : GWM --- main.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index afe0a50..b96b614 100755 --- a/main.go +++ b/main.go @@ -2222,7 +2222,11 @@ func main() { // Serve static files from the provided public directory (if exists) app.OnBeforeServe().Add(func(e *core.ServeEvent) error { - e.Router.GET("/verify-email", verifyEmailHandler) + // e.Router.GET("/verify-email", verifyEmailHandler) + + e.Router.GET("/verify-email", func(c echo.Context) error { + return verifyEmailHandler(c, baseUrl) + }) e.Router.GET("/*", apis.StaticDirectoryHandler(os.DirFS("./pb_public"), false)) return nil }) @@ -2501,7 +2505,7 @@ func generateOTP() (int, error) { } // Email verification handler -func verifyEmailHandler(c echo.Context) error { +func verifyEmailHandler(c echo.Context, baseUrl string) error { log.Println("Starting verifyEmailHandler") // Get the userId from the query parameter