mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-26 00:03:16 +00:00
Update StatusDelete pipeline
This commit is contained in:
parent
243c62e73f
commit
7492194cc2
1 changed files with 9 additions and 3 deletions
|
@ -2,9 +2,12 @@
|
||||||
|
|
||||||
namespace App\Jobs\StatusPipeline;
|
namespace App\Jobs\StatusPipeline;
|
||||||
|
|
||||||
use App\Notification;
|
use App\{
|
||||||
use App\Status;
|
Notification,
|
||||||
use App\StatusHashtag;
|
Report,
|
||||||
|
Status,
|
||||||
|
StatusHashtag,
|
||||||
|
};
|
||||||
use Illuminate\Bus\Queueable;
|
use Illuminate\Bus\Queueable;
|
||||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
||||||
use Illuminate\Foundation\Bus\Dispatchable;
|
use Illuminate\Foundation\Bus\Dispatchable;
|
||||||
|
@ -73,6 +76,9 @@ class StatusDelete implements ShouldQueue
|
||||||
->whereItemId($status->id)
|
->whereItemId($status->id)
|
||||||
->delete();
|
->delete();
|
||||||
StatusHashtag::whereStatusId($status->id)->delete();
|
StatusHashtag::whereStatusId($status->id)->delete();
|
||||||
|
Report::whereObjectType('App\Status')
|
||||||
|
->whereObjectId($status->id)
|
||||||
|
->delete();
|
||||||
$status->delete();
|
$status->delete();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in a new issue