Fix tests
This commit is contained in:
@@ -76,7 +76,7 @@ class ReportIncidentCommandHandler
|
|||||||
}
|
}
|
||||||
|
|
||||||
// The incident occurred at a different time.
|
// The incident occurred at a different time.
|
||||||
if ($occurredAt = $command->occurredAt) {
|
if ($occurredAt = $command->occurred_at) {
|
||||||
if ($date = $this->dates->create('Y-m-d H:i', $occurredAt)) {
|
if ($date = $this->dates->create('Y-m-d H:i', $occurredAt)) {
|
||||||
$incident->fill(['occurred_at' => $date]);
|
$incident->fill(['occurred_at' => $date]);
|
||||||
} else {
|
} else {
|
||||||
@@ -129,7 +129,7 @@ class ReportIncidentCommandHandler
|
|||||||
'visible' => $command->visible,
|
'visible' => $command->visible,
|
||||||
'notify' => $command->notify,
|
'notify' => $command->notify,
|
||||||
'stickied' => $command->stickied,
|
'stickied' => $command->stickied,
|
||||||
'occurredAt' => $command->occurredAt,
|
'occurred_at' => $command->occurred_at,
|
||||||
'component' => Component::find($command->component_id) ?: null,
|
'component' => Component::find($command->component_id) ?: null,
|
||||||
'component_status' => $command->component_status,
|
'component_status' => $command->component_status,
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -65,7 +65,7 @@ class UpdateIncidentCommandHandler
|
|||||||
$incident->fill($this->filter($command));
|
$incident->fill($this->filter($command));
|
||||||
|
|
||||||
// The incident occurred at a different time.
|
// The incident occurred at a different time.
|
||||||
if ($occurredAt = $command->occurredAt) {
|
if ($occurredAt = $command->occurred_at) {
|
||||||
if ($date = $this->dates->create('Y-m-d H:i', $occurredAt)) {
|
if ($date = $this->dates->create('Y-m-d H:i', $occurredAt)) {
|
||||||
$incident->fill(['occurred_at' => $date]);
|
$incident->fill(['occurred_at' => $date]);
|
||||||
} else {
|
} else {
|
||||||
@@ -141,7 +141,7 @@ class UpdateIncidentCommandHandler
|
|||||||
'visible' => $command->visible,
|
'visible' => $command->visible,
|
||||||
'notify' => $command->notify,
|
'notify' => $command->notify,
|
||||||
'stickied' => $command->stickied,
|
'stickied' => $command->stickied,
|
||||||
'occurredAt' => $command->occurredAt,
|
'occurred_at' => $command->occurred_at,
|
||||||
'component' => Component::find($command->component_id) ?: null,
|
'component' => Component::find($command->component_id) ?: null,
|
||||||
'component_status' => $command->component_status,
|
'component_status' => $command->component_status,
|
||||||
],
|
],
|
||||||
|
|||||||
Reference in New Issue
Block a user