Refactor findNull to find

This commit is contained in:
James Cole
2021-06-30 06:17:38 +02:00
parent b7ae5eda35
commit 70da5917c9
68 changed files with 120 additions and 273 deletions

View File

@@ -104,8 +104,8 @@ class UpdateRequest extends FormRequest
$inwardId = $data['inward_id'] ?? $existing->source_id;
$outwardId = $data['outward_id'] ?? $existing->destination_id;
$inward = $journalRepos->findNull((int)$inwardId);
$outward = $journalRepos->findNull((int)$outwardId);
$inward = $journalRepos->find((int)$inwardId);
$outward = $journalRepos->find((int)$outwardId);
if (null === $inward) {
$inward = $existing->source;
}