Rubenwouters\CrmLauncher\Controllers\PublishController::deleteReaction PHP Method

deleteReaction() public method

Delete reaction
public deleteReaction ( integer $id ) : view
$id integer
return view
    public function deleteReaction($id)
    {
        $reaction = $this->reaction->find($id);
        $reaction->delete();
        if ($reaction->fb_post_id != '') {
            $this->facebookContent->deleteFbPost($reaction);
        }
        if ($reaction->tweet_id != '') {
            $this->twitterContent->deleteTweetPublishment($reaction);
        }
        return back();
    }