Skip to content

Commit

Permalink
Add check in SubmissionFile for dependent files capability
Browse files Browse the repository at this point in the history
  • Loading branch information
asmecher committed Aug 9, 2018
1 parent a1f5561 commit 7fdf0fa
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ function authorize($request, &$args, $roleAssignments) {
// Authorize review round id when this handler is used in review stages -- except
// for query files, which belong to the stage rather than the review round.
import('lib.pkp.classes.submission.SubmissionFile');
if (($stageId == WORKFLOW_STAGE_ID_INTERNAL_REVIEW || $stageId == WORKFLOW_STAGE_ID_EXTERNAL_REVIEW) && $request->getUserVar('fileStage') != SUBMISSION_FILE_QUERY) {
if (($stageId == WORKFLOW_STAGE_ID_INTERNAL_REVIEW || $stageId == WORKFLOW_STAGE_ID_EXTERNAL_REVIEW) && !in_array($request->getUserVar('fileStage'), array(SUBMISSION_FILE_QUERY, SUBMISSION_FILE_DEPENDENT))) {
import('lib.pkp.classes.security.authorization.internal.ReviewRoundRequiredPolicy');
$this->addPolicy(new ReviewRoundRequiredPolicy($request, $args));
}
Expand Down

0 comments on commit 7fdf0fa

Please sign in to comment.