mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-14 02:24:31 +00:00
Update SharePipeline
This commit is contained in:
parent
13bdaa2ed4
commit
5a19daabce
2 changed files with 6 additions and 3 deletions
|
@ -49,7 +49,10 @@ class SharePipeline implements ShouldQueue
|
||||||
public function handle()
|
public function handle()
|
||||||
{
|
{
|
||||||
$status = $this->status;
|
$status = $this->status;
|
||||||
$parent = $this->status->parent();
|
$parent = Status::find($this->status->reblog_of_id);
|
||||||
|
if(!$parent) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
$actor = $status->profile;
|
$actor = $status->profile;
|
||||||
$target = $parent->profile;
|
$target = $parent->profile;
|
||||||
|
|
||||||
|
@ -84,7 +87,7 @@ class SharePipeline implements ShouldQueue
|
||||||
|
|
||||||
public function remoteAnnounceDeliver()
|
public function remoteAnnounceDeliver()
|
||||||
{
|
{
|
||||||
if(config_cache('federation.activitypub.enabled') == false) {
|
if(config('app.env') !== 'production' || config_cache('federation.activitypub.enabled') == false) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
$status = $this->status;
|
$status = $this->status;
|
||||||
|
|
|
@ -70,7 +70,7 @@ class UndoSharePipeline implements ShouldQueue
|
||||||
|
|
||||||
public function remoteAnnounceDeliver()
|
public function remoteAnnounceDeliver()
|
||||||
{
|
{
|
||||||
if(config_cache('federation.activitypub.enabled') == false) {
|
if(config('app.env') !== 'production' || config_cache('federation.activitypub.enabled') == false) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue