Commit 0337d424 authored by Matija Obreza's avatar Matija Obreza

Fix: listAccessions permissions check expression

parent 37e986a5
......@@ -383,7 +383,7 @@ public class DatasetServiceImpl implements DatasetService {
* {@inheritDoc}
*/
@Override
@PreAuthorize("hasRole('ADMINISTRATOR') || dataset.published || hasPermission(dataset, 'read')")
@PreAuthorize("hasRole('ADMINISTRATOR') || #dataset.published || hasPermission(#dataset, 'read')")
public Page<AccessionRef> listAccessions(Dataset dataset, final Pageable page) {
dataset = loadDataset(dataset);
final List<AccessionRef> accessionRefs = new ArrayList<AccessionRef>(dataset.getAccessionRefs());
......
......@@ -108,7 +108,7 @@ public class SubsetServiceImpl implements SubsetService {
}
@Override
@PreAuthorize("hasRole('ADMINISTRATOR') || subset.published || hasPermission(subset, 'read')")
@PreAuthorize("hasRole('ADMINISTRATOR') || #subset.published || hasPermission(#subset, 'read')")
public Page<AccessionRef> listAccessions(Subset subset, final Pageable page) {
subset = loadSubset(subset);
final List<AccessionRef> accessionRefs = new ArrayList<AccessionRef>(subset.getAccessionRefs());
......
Markdown is supported
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