Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
X
xpub-faraday
Manage
Activity
Members
Labels
Plan
Issues
2
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container Registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
xpub
xpub-faraday
Commits
9ac14acd
Commit
9ac14acd
authored
6 years ago
by
Bogdan Cochior
Browse files
Options
Downloads
Plain Diff
Merge branch 'develop' of
https://gitlab.coko.foundation/xpub/xpub-faraday
into develop
parents
eed0983c
e05256e4
No related branches found
No related tags found
1 merge request
!6
Agree/Decline to work on a manuscript
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
packages/xpub-faraday/config/authsome.js
+18
-19
18 additions, 19 deletions
packages/xpub-faraday/config/authsome.js
with
18 additions
and
19 deletions
packages/xpub-faraday/config/authsome.js
+
18
−
19
View file @
9ac14acd
...
@@ -25,25 +25,24 @@ async function teamPermissions(user, operation, object, context) {
...
@@ -25,25 +25,24 @@ async function teamPermissions(user, operation, object, context) {
if
(
collectionsPermissions
.
length
>
0
)
{
if
(
collectionsPermissions
.
length
>
0
)
{
return
{
return
{
filter
:
filterParam
=>
{
filter
:
filterParam
=>
{
if
(
filterParam
.
length
>
0
)
{
if
(
!
filterParam
.
length
)
return
filterParam
const
collections
=
filterParam
.
map
(
coll
=>
{
const
collections
=
filterParam
const
matchingCollPerm
=
collectionsPermissions
.
find
(
.
map
(
coll
=>
{
collPerm
=>
coll
.
id
===
collPerm
.
id
,
const
matchingCollPerm
=
collectionsPermissions
.
find
(
)
collPerm
=>
coll
.
id
===
collPerm
.
id
,
if
(
matchingCollPerm
===
undefined
)
{
)
return
null
if
(
matchingCollPerm
===
undefined
)
{
}
return
null
coll
.
visibleStatus
=
statuses
[
coll
.
status
].
public
}
if
(
!
publicPermissions
.
includes
(
matchingCollPerm
.
permission
))
{
coll
.
visibleStatus
=
statuses
[
coll
.
status
].
public
coll
.
visibleStatus
=
statuses
[
coll
.
status
].
private
if
(
!
publicPermissions
.
includes
(
matchingCollPerm
.
permission
))
{
}
coll
.
visibleStatus
=
statuses
[
coll
.
status
].
private
return
coll
}
})
return
coll
.
filter
(
Boolean
)
})
return
collections
.
filter
(
Boolean
)
}
return
collections
return
filterParam
},
},
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
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