Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
GraceDB Server
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michael Coughlin
GraceDB Server
Commits
3325617a
Commit
3325617a
authored
9 years ago
by
Branson Craig Stephens
Browse files
Options
Downloads
Patches
Plain Diff
Fixed bug with perm modifying views in REST API.
parent
fff441d0
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
gracedb/api.py
+2
-2
2 additions, 2 deletions
gracedb/api.py
with
2 additions
and
2 deletions
gracedb/api.py
+
2
−
2
View file @
3325617a
...
...
@@ -1320,7 +1320,7 @@ class GroupEventPermissionDetail(APIView):
@group_required
@event_perm_object_required
def
put
(
self
,
request
,
event
,
group
,
permission
):
if
not
request
.
user
.
has_perm
(
"
guardian.groupobjectpermission
_add
"
):
if
not
request
.
user
.
has_perm
(
"
guardian.
add_
groupobjectpermission
"
):
return
HttpResponseForbidden
(
"
You don
'
t have permission to change permission objects.
"
)
# Get or create the GroupObjectPermission object
...
...
@@ -1376,7 +1376,7 @@ class GroupEventPermissionDetail(APIView):
@event_perm_object_required
def
delete
(
self
,
request
,
event
,
group
,
permission
):
if
not
request
.
user
.
has_perm
(
"
guardian.groupobjectpermission
_delete
"
):
if
not
request
.
user
.
has_perm
(
"
guardian.
delete_
groupobjectpermission
"
):
return
HttpResponseForbidden
(
"
You don
'
t have permission to change permission objects.
"
)
# Get the GroupObjectPermission object
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment