Skip to content
Snippets Groups Projects
Commit 06e3c954 authored by Sebastian Mihalache's avatar Sebastian Mihalache
Browse files

fix public/private status

parent 371d9112
No related branches found
No related tags found
1 merge request!13Sprint #14
......@@ -51,7 +51,7 @@ class Collection {
async updateStatus({ newStatus }) {
this.collection.status = newStatus
this.collection.visibleStatus = statuses[this.collection.status].public
this.collection.visibleStatus = statuses[this.collection.status].private
await this.collection.save()
}
......
......@@ -119,7 +119,9 @@ async function authenticatedUser(user, operation, object, context) {
}
const collectionPermission = userPermissions.find(
p => p.objectId === collection.id,
p =>
p.objectId === collection.id ||
collection.fragments.includes(p.objectId),
)
if (
publicStatusesPermissions.includes(
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment