mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-24 01:22:21 +00:00
Fix loadRepository error when access user dashboard (#31719)
(cherry picked from commit 7b388630ecb4537f9bb04e55cbb10eb7cf83b9c5)
This commit is contained in:
parent
7850fa30a5
commit
2be49a3745
|
@ -181,6 +181,10 @@ func (status *CommitStatus) LocaleString(lang translation.Locale) string {
|
|||
|
||||
// HideActionsURL set `TargetURL` to an empty string if the status comes from Gitea Actions
|
||||
func (status *CommitStatus) HideActionsURL(ctx context.Context) {
|
||||
if status.RepoID == 0 {
|
||||
return
|
||||
}
|
||||
|
||||
if status.Repo == nil {
|
||||
if err := status.loadRepository(ctx); err != nil {
|
||||
log.Error("loadRepository: %v", err)
|
||||
|
|
Loading…
Reference in a new issue