Skip to content
Snippets Groups Projects
Commit 92635971 authored by Tim Repke's avatar Tim Repke
Browse files

add missing permission dependency

parent 1ed08f45
No related branches found
No related tags found
No related merge requests found
Pipeline #785 passed
......@@ -75,7 +75,8 @@ async def put_annotation_scheme(annotation_scheme: AnnotationSchemeModel,
@router.delete('/schemes/definition/{scheme_id}')
async def remove_annotation_scheme(annotation_scheme_id: str) -> None:
async def remove_annotation_scheme(annotation_scheme_id: str,
permissions=Depends(UserPermissionChecker('annotations_edit'))) -> None:
await delete_annotation_scheme(annotation_scheme_id=annotation_scheme_id, engine=db_engine)
......@@ -231,7 +232,7 @@ async def get_annotations(assignment_scope_id: str, permissions=Depends(UserPerm
return assignments
@router.post('/annotate/save')
@router.post('/annotate/save', response_model=AssignmentStatus)
async def save_annotation(annotated_item: AnnotatedItem,
permissions=Depends(UserPermissionChecker('annotations_read'))) -> AssignmentStatus:
# double-check, that the supposed assignment actually exists
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment