mirror of
https://github.com/go-gitea/gitea.git
synced 2026-11-13 22:47:41 +00:00
Add more check for stopwatch read or list (#36340)
This commit is contained in:
1 parent
ed5720af2a
commit
95ea2df00a
9 files changed
+160
-7
No files matched your search
@@ -120,6 +120,11 @@ func ReconsiderWatches(ctx context.Context, repo *repo_model.Repository, user *u
|
||||
return err
|
||||
}
|
||||
|
||||
// Remove all stopwatches a user has running in the repository
|
||||
if err := issues_model.RemoveStopwatchesByRepoID(ctx, user.ID, repo.ID); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Remove all IssueWatches a user has subscribed to in the repository
|
||||
return issues_model.RemoveIssueWatchersByRepoID(ctx, user.ID, repo.ID)
|
||||
}
|
||||
Reference in new issue
Block a user