Explorar o código

Update DeleteWorker, fixes #3338

Daniel Supernault %!s(int64=3) %!d(string=hai) anos
pai
achega
b424691110
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      app/Jobs/InboxPipeline/DeleteWorker.php

+ 3 - 0
app/Jobs/InboxPipeline/DeleteWorker.php

@@ -213,6 +213,9 @@ class DeleteWorker implements ShouldQueue
 		  'User-Agent' => 'PixelfedBot v0.1 - https://pixelfed.org',
 		])->get($actor->remote_url);
 		$res = json_decode($res->body(), true, 8);
+		if(!isset($res['publicKey'], $res['publicKey']['id'])) {
+			return;
+		}
 		if($res['publicKey']['id'] !== $actor->key_id) {
 			return;
 		}