Minor bug in OJS 2.4.x ReviewerAction::recordRecommendation

In our OJS PHP log file I noticed the following error:

NOTICE: Undefined property: ReviewAssignment::$getRecommendation (/var/www/ojs-2.4.3/classes/submission/reviewer/ReviewerAction.inc.php

It arises due to a trivial error in the ReviewerAction::recordRecommendation function at around line 130. The line currently reads:

if ($reviewAssignment->getRecommendation() === null || $reviewAssignment->getRecommendation === ‘’) {

The second condition in that if statement is missing a pair of parenthese after getRecommendation, so the token is treated as a class property (i.e. a member variable) that doesn’t exist rather than a call to a function, which is what it’s supposed to be.

The issue is present in the most recent version of 2.4.8 on github, but it is not a significant bug–it’s just cosmetic. It can only be triggered if a reviewer recommendation had been previously submitted and another attempt to submit a recommendation is made. As far as I can tell, this should not be possible since recommendations are supposed to be final. Perhaps if a reviewer hits refresh on their browser while this form is being POSTED, a second invocation of the SubmissionReviewHandler:recordRecommendation occurs. Looking through the error log, I notice that a dozen of these errors have occurred over the last couple years, over which time we’ve had thousands of successful reviews submitted. So it’s not a big issue.


Hi @rkemp,

Thanks for the heads-up – yes, that looks like a good diagnosis/solution. I’ve committed the fix at Correct missing function call (cosmetic) · pkp/ojs@f0f718d · GitHub for release in whatever OJS 2.4.x is released next.

Alec Smecher
Public Knowledge Project Team