Have webmentions sent automatically

This commit is contained in:
Jonny Barnes 2016-06-23 14:27:00 +01:00
parent 44060da577
commit e31364e787
7 changed files with 49 additions and 11 deletions

View file

@ -22,7 +22,7 @@ class SendWebMentions extends Job implements ShouldQueue
* @param Note $note
* @return void
*/
public function __construct(Note $note, Client $guzzle)
public function __construct(Note $note, Client $guzzle = null)
{
$this->note = $note;
$this->guzzle = $guzzle ?? new Client();
@ -47,7 +47,7 @@ class SendWebMentions extends Job implements ShouldQueue
'source' => $this->note->longurl,
'target' => $url
]
])
]);
}
}
}