mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-19 05:47:53 +08:00
Merge pull request #3390 from artoscinote/ma_SCI_5634
Fix illegal return statement [SCI-5634]
This commit is contained in:
commit
2033d098ac
1 changed files with 5 additions and 3 deletions
|
@ -25,9 +25,11 @@ Canaid::Permissions.register_for(Asset) do
|
|||
when Result
|
||||
can_manage_result?(object)
|
||||
when RepositoryCell
|
||||
return false if object.repository_column.repository.is_a?(RepositorySnapshot)
|
||||
|
||||
can_manage_repository?(user, object.repository_column.repository)
|
||||
if object.repository_column.repository.is_a?(RepositorySnapshot)
|
||||
false
|
||||
else
|
||||
can_manage_repository?(user, object.repository_column.repository)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue