Skip to content

Commit

Permalink
Fixed issue: XSS filter for attributes is applied when the participan…
Browse files Browse the repository at this point in the history
…t is marked as completed or quota out
  • Loading branch information
c-schmitz committed Oct 5, 2016
1 parent 3bad8ca commit 160b48a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion application/helpers/frontend_helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ function submittokens($quotaexit=false)
$today = dateShift(date("Y-m-d H:i:s"), "Y-m-d H:i", Yii::app()->getConfig("timeadjust"));

// check how many uses the token has left
$token = Token::model($surveyid)->findByAttributes(array('token' => $clienttoken));
$token = Token::model($surveyid,'FinalSubmit')->findByAttributes(array('token' => $clienttoken));

if ($quotaexit==true)
{
Expand Down
2 changes: 1 addition & 1 deletion application/models/Token.php
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ public function rules()
);
foreach (decodeTokenAttributes($this->survey->attributedescriptions) as $key => $info)
{
$aRules[]=array($key,'LSYii_Validators');
$aRules[]=array($key,'LSYii_Validators','except'=>'FinalSubmit');
}
return $aRules;
}
Expand Down

0 comments on commit 160b48a

Please sign in to comment.