diff options
| author | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2023-05-15 08:44:50 +0000 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+studip@gmail.com> | 2023-05-15 08:44:50 +0000 |
| commit | f7e75f5649318e3324bd1273e8959656b0118e29 (patch) | |
| tree | 88d026ef8885ff50e3c50c3da08df0e2fb431d91 /lib/filesystem/StandardFile.php | |
| parent | 3a66ef5a66a3017ee526e153a373f79373450677 (diff) | |
connect oer share action with configurable perms, fixes #2638
Closes #2638
Merge request studip/studip!1795
Diffstat (limited to 'lib/filesystem/StandardFile.php')
| -rw-r--r-- | lib/filesystem/StandardFile.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/filesystem/StandardFile.php b/lib/filesystem/StandardFile.php index 371f041..4547d37 100644 --- a/lib/filesystem/StandardFile.php +++ b/lib/filesystem/StandardFile.php @@ -294,7 +294,11 @@ class StandardFile implements FileType, ArrayAccess, StandardFileInterface 'link-to-clipboard' ); } - if ($this->isEditable($GLOBALS['user']->id) && Config::get()->OERCAMPUS_ENABLED) { + if ( + $this->isEditable($GLOBALS['user']->id) + && Config::get()->OERCAMPUS_ENABLED + && $GLOBALS['perm']->have_perm(Config::get()->OER_PUBLIC_STATUS) + ) { $actionMenu->addLink( URLHelper::getURL('dispatch.php/file/share_oer/' . $this->fileref->id), _('Im OER Campus veröffentlichen'), |
