summaryrefslogtreecommitdiffstats
path: root/models/fixtures
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2023-11-26 01:21:21 +0800
committerGitHub <noreply@github.com>2023-11-25 17:21:21 +0000
commit882e5023270ed844a4b2911e555e82fe905869e4 (patch)
tree4d0d28ccf485e123ea7cbe719e7a414065ffba17 /models/fixtures
parent80217cacfc3fcf0ffa0dc203843c11e318f85d19 (diff)
downloadgitea-882e5023270ed844a4b2911e555e82fe905869e4.tar.gz
gitea-882e5023270ed844a4b2911e555e82fe905869e4.zip
Fix comment permissions (#28213)
This PR will fix some missed checks for private repositories' data on web routes and API routes.
Diffstat (limited to 'models/fixtures')
-rw-r--r--models/fixtures/comment.yml9
-rw-r--r--models/fixtures/issue.yml2
2 files changed, 10 insertions, 1 deletions
diff --git a/models/fixtures/comment.yml b/models/fixtures/comment.yml
index bd64680c8c..17586caa21 100644
--- a/models/fixtures/comment.yml
+++ b/models/fixtures/comment.yml
@@ -66,3 +66,12 @@
tree_path: "README.md"
created_unix: 946684812
invalidated: true
+
+-
+ id: 8
+ type: 0 # comment
+ poster_id: 2
+ issue_id: 4 # in repo_id 2
+ content: "comment in private pository"
+ created_unix: 946684811
+ updated_unix: 946684811
diff --git a/models/fixtures/issue.yml b/models/fixtures/issue.yml
index ccc1fe41fb..0c9b6ff406 100644
--- a/models/fixtures/issue.yml
+++ b/models/fixtures/issue.yml
@@ -61,7 +61,7 @@
priority: 0
is_closed: true
is_pull: false
- num_comments: 0
+ num_comments: 1
created_unix: 946684830
updated_unix: 978307200
is_locked: false