From 464a046019d9fb2e1a21638ef0042d7d37aaa5d9 Mon Sep 17 00:00:00 2001 From: Jared P Bostic Date: Wed, 2 Sep 2020 16:35:55 -0500 Subject: [PATCH] Redirect to /user/edit path only needed if we are admin. --- cmd/subspace/handlers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/subspace/handlers.go b/cmd/subspace/handlers.go index f89e2827..63ae5c67 100644 --- a/cmd/subspace/handlers.go +++ b/cmd/subspace/handlers.go @@ -501,7 +501,7 @@ func profileDeleteHandler(w *Web) { w.Redirect("/profile/delete?error=deleteprofile") return } - if profile.UserID != "" { + if w.Admin { w.Redirect("/user/edit/%s?success=deleteprofile", profile.UserID) return }