File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -124,8 +124,8 @@ public function response_complete($responsedata) {
124
124
) {
125
125
$ answer = reset ($ responsedata ->answers [$ this ->id ]);
126
126
$ answered = ((int )$ answer ->value > 0 );
127
- // If $responsedata is webform data, check that it is not empty.
128
127
} else if (isset ($ responsedata ->{'q ' .$ this ->id })) {
128
+ // If $responsedata is webform data, check that it is not empty.
129
129
$ draftitemid = (int )$ responsedata ->{'q ' . $ this ->id };
130
130
if ($ draftitemid > 0 ) {
131
131
$ info = file_get_draft_area_info ($ draftitemid );
Original file line number Diff line number Diff line change @@ -119,17 +119,17 @@ public static function response_answers_by_question($rid) {
119
119
/**
120
120
* Delete old entries from the questionnaire_response_file table and also the corresponding entries
121
121
* in the files table.
122
- * @param int $question_id
123
- * @param int $response_id
122
+ * @param int $questionid
123
+ * @param int $responseid
124
124
* @return void
125
125
* @throws \dml_exception
126
126
*/
127
- public static function delete_old_response (int $ question_id , int $ response_id ) {
127
+ public static function delete_old_response (int $ questionid , int $ responseid ) {
128
128
global $ DB ;
129
129
// Check, if we have an old response file from a former attempt.
130
130
$ record = $ DB ->get_record (static ::response_table (), [
131
- 'response_id ' => $ response_id ,
132
- 'question_id ' => $ question_id ,
131
+ 'response_id ' => $ responseid ,
132
+ 'question_id ' => $ questionid ,
133
133
]);
134
134
if ($ record ) {
135
135
// Old record found, then delete all referenced entries in the files table and then delete this entry.
You can’t perform that action at this time.
0 commit comments