Skip to content

Commit

Permalink
Update Import.php
Browse files Browse the repository at this point in the history
  • Loading branch information
webong committed Oct 25, 2023
1 parent 921f822 commit 45e904d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Ushahidi/Modules/V3/Listener/Import.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ public function handle(
// ... transform record
$entity = $this->transform($record);

// Ensure that under review is correctly mapped to draft
if (strcasecmp($entity->status, 'under review')== 0) {
// Ensure that empty status or under review is correctly mapped to draft
if (is_null($entity->status) || strcasecmp($entity->status, 'under review') == 0) {
$entity->setState(['status' => 'draft']);
}

Expand Down

0 comments on commit 45e904d

Please sign in to comment.