mirror of
https://github.com/CachetHQ/Cachet.git
synced 2025-01-17 13:38:20 +01:00
Use create instead of createNormalized on handlers
This commit is contained in:
parent
1ddd868449
commit
537017925f
@ -69,7 +69,7 @@ class ReportIncidentCommandHandler
|
||||
|
||||
// The incident occurred at a different time.
|
||||
if ($command->incident_date) {
|
||||
$incidentDate = $this->dates->createNormalized('d/m/Y H:i', $command->incident_date);
|
||||
$incidentDate = $this->dates->create('d/m/Y H:i', $command->incident_date);
|
||||
|
||||
$data['created_at'] = $incidentDate;
|
||||
$data['updated_at'] = $incidentDate;
|
||||
|
@ -46,7 +46,7 @@ class ReportMaintenanceCommandHandler
|
||||
*/
|
||||
public function handle(ReportMaintenanceCommand $command)
|
||||
{
|
||||
$scheduledAt = $this->dates->createNormalized('d/m/Y H:i', $command->timestamp);
|
||||
$scheduledAt = $this->dates->create('d/m/Y H:i', $command->timestamp);
|
||||
|
||||
$maintenanceEvent = Incident::create([
|
||||
'name' => $command->name,
|
||||
|
@ -59,7 +59,7 @@ class UpdateIncidentCommandHandler
|
||||
|
||||
// The incident occurred at a different time.
|
||||
if ($command->incident_date) {
|
||||
$incidentDate = $this->dates->createNormalized('d/m/Y H:i', $command->incident_date);
|
||||
$incidentDate = $this->dates->create('d/m/Y H:i', $command->incident_date);
|
||||
|
||||
$incident->update([
|
||||
'created_at' => $incidentDate,
|
||||
|
Loading…
x
Reference in New Issue
Block a user