Skip to content

Commit

Permalink
Dev: Fix issue with non-array after event in EM
Browse files Browse the repository at this point in the history
  • Loading branch information
olleharstedt committed Apr 21, 2020
1 parent 92bfd51 commit e49aeb1
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions application/helpers/expressions/em_manager_helper.php
Expand Up @@ -4417,8 +4417,12 @@ public function setVariableAndTokenMappingsForExpressionManager($surveyid,$force
$this->knownVars = $result->get('knownVars');
$this->questionSeq2relevance = $result->get('questionSeq2relevance');
$this->runtimeTimings[] = array(__METHOD__ . ' - process fieldMap',(microtime(true) - $now));
usort($this->questionSeq2relevance,'cmpQuestionSeq');
$this->numQuestions = count($this->questionSeq2relevance);
if (!empty($this->questionSeq2relevance)) {
usort($this->questionSeq2relevance,'cmpQuestionSeq');
$this->numQuestions = count($this->questionSeq2relevance);
} else {
$this->numQuestions = 0;
}
$this->numGroups = count($this->groupSeqInfo);
return true;
}
Expand Down

0 comments on commit e49aeb1

Please sign in to comment.