Skip to content

Commit

Permalink
Handle if a duplicate case is in the db
Browse files Browse the repository at this point in the history
  • Loading branch information
Phil E. Taylor committed Nov 16, 2018
1 parent 058b822 commit 235df8d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions components/com_privacy/models/request.php
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,11 @@ public function removeRequest($id = null)
$id = $this->getState($this->getName() . '.id');
}

// This can happen if a duplicate request was attempted, so the new request was not created, and so doesnt need to be deleted
if (!$id){
return false;
}

/** @var PrivacyTableRequest $table */
$table = $this->getTable();

Expand Down

0 comments on commit 235df8d

Please sign in to comment.