Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions lib/Service/ApprovalService.php
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,9 @@ public function request(int $fileId, int $ruleId, ?string $userId, bool $createS
}

if ($this->userIsAuthorizedByRule($userId, $rule, 'requesters')) {
if ($this->tagObjectMapper->haveTag((string)$fileId, 'files', $rule['tagApproved'])) {
return ['error' => $this->l10n->t('Approval has already been granted with this rule for this file')];
}
// only request if it has not yet been requested for this rule
if (!$this->tagObjectMapper->haveTag((string)$fileId, 'files', $rule['tagPending'])) {
if ($createShares) {
Expand Down
Loading