mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-08-01 17:38:33 +00:00
Fix unclear "Owner" concept (#24233)
Some user/org pages use `Owner` variable. It's an incorrect concept since year 2016: what is a user's owner? Actually, new code is right: use `ContextUser`. This PR cleans all legacy "Owner" variables. ## Screenshots for related pages and test results All pages are as before: ### `web/org/home.go`  ### `web/user/profile.go`  ### `web/user/setting/profile.go` 
This commit is contained in:
parent
8ea33baa1c
commit
70fc47a22a
8 changed files with 40 additions and 41 deletions
|
@ -30,12 +30,12 @@
|
|||
</style>
|
||||
</noscript>
|
||||
{{if .PageIsUserProfile}}
|
||||
<meta property="og:title" content="{{.Owner.DisplayName}}">
|
||||
<meta property="og:title" content="{{.ContextUser.DisplayName}}">
|
||||
<meta property="og:type" content="profile">
|
||||
<meta property="og:image" content="{{.Owner.AvatarLink $.Context}}">
|
||||
<meta property="og:url" content="{{.Owner.HTMLURL}}">
|
||||
{{if .Owner.Description}}
|
||||
<meta property="og:description" content="{{.Owner.Description}}">
|
||||
<meta property="og:image" content="{{.ContextUser.AvatarLink $.Context}}">
|
||||
<meta property="og:url" content="{{.ContextUser.HTMLURL}}">
|
||||
{{if .ContextUser.Description}}
|
||||
<meta property="og:description" content="{{.ContextUser.Description}}">
|
||||
{{end}}
|
||||
{{else if .Repository}}
|
||||
{{if .Issue}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue