Skip to content

Commit

Permalink
php warning fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
sjpadgett committed Jun 16, 2024
1 parent c38de3a commit e348a00
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public function processWenoPharmacyCsv($filePath, bool $isInsertOnly = true): fa
}
$rowNumber++;

$record = array_map(fn($item) => str_replace(['[', ']'], '', trim($item)), $record);
$record = array_map(fn($item) => str_replace(['[', ']'], '', trim($item ?? '')), $record);
$dateTime = \DateTime::createFromFormat('m/d/Y h:i:s A', $record['Created']);
$record['Created'] = $dateTime ? $dateTime->format('Y-m-d H:i:s') : null;
$dateTime = \DateTime::createFromFormat('m/d/Y h:i:s A', $record['Modified']);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function updatePatientWenoPharmacy($pid, $data)
public function getWenoLastSearch($pid)
{
$sql = "SELECT `search_persist` FROM weno_assigned_pharmacy WHERE pid = ?";
return json_decode(sqlQuery($sql, array($pid))['search_persist']);
return json_decode(sqlQuery($sql, array($pid))['search_persist'] ?? '');
}

public function getWenoPrimaryPharm($pid): false|array|null
Expand Down

0 comments on commit e348a00

Please sign in to comment.