Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
coopwire-hypothesis
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
孙灵跃 Leon Sun
coopwire-hypothesis
Commits
a92fe7cb
Commit
a92fe7cb
authored
Oct 23, 2014
by
Randall Leeds
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1585 from hypothesis/fix-replies
Only add the public principal to the annotation
parents
da17c8cc
170d438f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
annotation.coffee
h/static/scripts/directives/annotation.coffee
+5
-5
No files found.
h/static/scripts/directives/annotation.coffee
View file @
a92fe7cb
...
@@ -160,13 +160,13 @@ AnnotationController = [
...
@@ -160,13 +160,13 @@ AnnotationController = [
# Construct the reply.
# Construct the reply.
references = [references..., id]
references = [references..., id]
# If replying to a public annotation make the response public.
reply = {references, uri}
if 'group:__world__' in model.permissions.read or []
permissions = {read: ['group:__world__']}
reply = {references, uri, permissions}
annotator.publish 'beforeAnnotationCreated', reply
annotator.publish 'beforeAnnotationCreated', reply
# If replying to a public annotation make the response public.
if 'group:__world__' in (model.permissions.read or [])
reply.permissions.read.push('group:__world__')
###
*
###
*
# @ngdoc method
# @ngdoc method
# @name annotation.AnnotationController#render
# @name annotation.AnnotationController#render
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment