Skip to content

Commit b5914fc

Browse files
fix lint
1 parent d3959f6 commit b5914fc

File tree

3 files changed

+13
-11
lines changed

3 files changed

+13
-11
lines changed

api/app/Http/Controllers/Forms/FormSubmissionController.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public function export(FormSubmissionExportRequest $request, string $id)
5555
$this->authorize('view', $form);
5656

5757
$allRows = [];
58-
$displayColumns = collect($request->columns)->filter(fn($value, $key) => $value === true)->toArray();
58+
$displayColumns = collect($request->columns)->filter(fn ($value, $key) => $value === true)->toArray();
5959
foreach ($form->submissions->toArray() as $row) {
6060
$formatter = (new FormSubmissionFormatter($form, $row['data']))
6161
->outputStringsOnly()
@@ -66,7 +66,7 @@ public function export(FormSubmissionExportRequest $request, string $id)
6666
$formattedData = $formatter->getCleanKeyValue();
6767
$filteredData = ['id' => Hashids::encode($row['id'])];
6868
foreach ($displayColumns as $column => $value) {
69-
$key = collect($formattedData)->keys()->first(fn($key) => str_contains($key, $column));
69+
$key = collect($formattedData)->keys()->first(fn ($key) => str_contains($key, $column));
7070
if ($key) {
7171
$filteredData[$key] = $formattedData[$key];
7272
}

api/app/Http/Controllers/Forms/PublicFormController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ public function answer(AnswerFormRequest $request, FormSubmissionProcessor $form
170170

171171
/**
172172
* Process submission hash and ID to ensure consistent format
173-
*
173+
*
174174
* @param Request $request
175175
* @param array $submissionData
176176
* @return array

api/app/Jobs/Form/StoreFormSubmissionJob.php

+10-8
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,18 @@
2121

2222
/**
2323
* Job to store form submissions
24-
*
24+
*
2525
* This job handles the storage of form submissions, including processing of metadata
2626
* and special field types like files and signatures.
27-
*
27+
*
2828
* The job accepts all data in the submissionData array, including metadata fields:
2929
* - submission_id: ID of an existing submission to update (must be an integer)
3030
* - completion_time: Time in seconds it took to complete the form
3131
* - is_partial: Whether this is a partial submission (will be stored with STATUS_PARTIAL)
3232
* If not specified, submissions are treated as complete by default.
33-
*
33+
*
3434
* These metadata fields will be automatically extracted and removed from the stored form data.
35-
*
35+
*
3636
* For partial submissions:
3737
* - The submission will be stored with STATUS_PARTIAL
3838
* - All file uploads and signatures will be processed normally
@@ -57,7 +57,9 @@ class StoreFormSubmissionJob implements ShouldQueue
5757
* @param array $submissionData Form data including metadata fields (submission_id, completion_time, etc.)
5858
* @return void
5959
*/
60-
public function __construct(public Form $form, public array $submissionData) {}
60+
public function __construct(public Form $form, public array $submissionData)
61+
{
62+
}
6163

6264
/**
6365
* Execute the job.
@@ -87,7 +89,7 @@ public function handle()
8789

8890
/**
8991
* Extract metadata from submission data
90-
*
92+
*
9193
* This method extracts and removes metadata fields from the submission data:
9294
* - submission_id
9395
* - completion_time
@@ -128,7 +130,7 @@ public function getSubmissionId()
128130

129131
/**
130132
* Store the submission in the database
131-
*
133+
*
132134
* @param array $formData
133135
*/
134136
private function storeSubmission(array $formData)
@@ -318,7 +320,7 @@ private function addHiddenPrefills(array &$formData): void
318320

319321
/**
320322
* Get the processed form data including the submission ID
321-
*
323+
*
322324
* @return array
323325
*/
324326
public function getProcessedData(): array

0 commit comments

Comments
 (0)