Skip to content
This repository has been archived by the owner on Aug 16, 2024. It is now read-only.

fix: Don't allow deleting pre submission file uploads #130

Merged
merged 2 commits into from
Apr 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -287,15 +287,10 @@ public function financialEvidenceProcessFileUpload($file)
$this->getFinancialEvidenceData(true);
}

/**
* Get list of financial evidence documents
*
* @return array
*/
public function financialEvidenceLoadFileUpload()
/** Get list of financial evidence documents */
public function financialEvidenceLoadFileUpload(): array
{
$financialEvidenceData = $this->getFinancialEvidenceData();
return $financialEvidenceData['documents'];
return array_filter($this->getFinancialEvidenceData()['documents'], fn($doc) => $doc['isPostSubmissionUpload']);
}

/**
Expand Down Expand Up @@ -324,14 +319,10 @@ public function supportingEvidenceProcessFileUpload($file)
$this->getData(true);
}

/**
* Get list of supporting evidence documents
*
* @return array
*/
public function supportingEvidenceLoadFileUpload()
/** Get list of supporting evidence documents */
public function supportingEvidenceLoadFileUpload(): array
{
return $this->getData()['supportingEvidence'];
return array_filter($this->getData()['supportingEvidence'], fn($doc) => $doc['isPostSubmissionUpload']);
}

/**
Expand Down
Loading