Loading webform_scoring.module +7 −0 Changes for webform_scoring.module: 7 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -76,6 +76,10 @@ function _webform_score_enabled($nid) { */ function webform_scoring_calculate_score($node, $data) { $score_enabled = _webform_score_enabled($node->nid); // Scoring is not enabled for this node. // Note that this function returns a boolean. Thus return FALSE. if ($score_enabled == NULL) return FALSE; if ($score_enabled->enabled && _webform_score_has_cid($node, $score_enabled->cid)) { $query = db_select('webform_scoring_values_scores_pair', 'a'); $query->fields('a'); Loading Loading @@ -128,9 +132,12 @@ function webform_scoring_webform_submission_presave($node, &$submission) { if ($total_score !== FALSE) { $score_enabled = _webform_score_enabled($node->nid); // Scoring is not enabled for this node. if($score_enabled != NULL) { $submission->data[$score_enabled->cid][0] = $total_score; } } } /** * Check if the webform contains a certain component Loading Loading
webform_scoring.module +7 −0 Changes for webform_scoring.module: 7 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -76,6 +76,10 @@ function _webform_score_enabled($nid) { */ function webform_scoring_calculate_score($node, $data) { $score_enabled = _webform_score_enabled($node->nid); // Scoring is not enabled for this node. // Note that this function returns a boolean. Thus return FALSE. if ($score_enabled == NULL) return FALSE; if ($score_enabled->enabled && _webform_score_has_cid($node, $score_enabled->cid)) { $query = db_select('webform_scoring_values_scores_pair', 'a'); $query->fields('a'); Loading Loading @@ -128,9 +132,12 @@ function webform_scoring_webform_submission_presave($node, &$submission) { if ($total_score !== FALSE) { $score_enabled = _webform_score_enabled($node->nid); // Scoring is not enabled for this node. if($score_enabled != NULL) { $submission->data[$score_enabled->cid][0] = $total_score; } } } /** * Check if the webform contains a certain component Loading