From 30b18a4ced6937e552687d0ae07f1b6724cd20ee Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Sat, 17 Feb 2024 03:14:17 -0500 Subject: [PATCH] fix: update Routes signature --- api/account/account.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/account/account.go b/api/account/account.go index d9b41fd..2b6277a 100644 --- a/api/account/account.go +++ b/api/account/account.go @@ -193,7 +193,7 @@ func (a AccountAPI) otpDisable(jc jape.Context) { } } -func (a AccountAPI) Routes() *httprouter.Router { +func (a AccountAPI) Routes() (*httprouter.Router, error) { authMw2fa := authMiddleware(middleware.AuthMiddlewareOptions{ Identity: a.identity, Accounts: a.accounts, @@ -215,5 +215,5 @@ func (a AccountAPI) Routes() *httprouter.Router { "/api/auth/otp/verify": middleware.ApplyMiddlewares(a.otpVerify, authMw, middleware.ProxyMiddleware), "/api/auth/otp/validate": middleware.ApplyMiddlewares(a.otpValidate, authMw, middleware.ProxyMiddleware), "/api/auth/otp/disable": middleware.ApplyMiddlewares(a.otpDisable, authMw, middleware.ProxyMiddleware), - }) + }), nil }