We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c077a08 commit 69ea554Copy full SHA for 69ea554
routers/web/user/home.go
@@ -821,6 +821,11 @@ func UsernameSubRoute(ctx *context.Context) {
821
reloadParam := func(suffix string) (success bool) {
822
ctx.SetParams("username", strings.TrimSuffix(username, suffix))
823
context_service.UserAssignmentWeb()(ctx)
824
+ // check view permissions
825
+ if !user_model.IsUserVisibleToViewer(ctx, ctx.ContextUser, ctx.Doer) {
826
+ ctx.NotFound("user", fmt.Errorf(ctx.ContextUser.Name))
827
+ return false
828
+ }
829
return !ctx.Written()
830
}
831
switch {
0 commit comments