Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed Jul 10, 2024
1 parent c28c000 commit af28f42
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions src/Slack/SlackMessage.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class SlackMessage implements Arrayable
/**
* If sending message as reply to thread, whether to 'broadcast' a reference to the thread reply to the parent conversation.
*/
protected ?bool $replyBroadcast = null;
protected ?bool $broadcastReply = null;

/**
* Set the Slack channel the message should be sent to.
Expand Down Expand Up @@ -259,11 +259,11 @@ public function threadTimestamp(?string $threadTimestamp): self
}

/**
* Only applicable if threadTimestamp is set. 'Broadcasts' a reference to the threaded reply to the parent conversation.
* Only applicable if threadTimestamp is set. Broadcasts a reference to the threaded reply to the parent conversation.
*/
public function replyBroadcast(?bool $replyBroadcast): self
public function broadcastReply(?bool $broadcastReply = true): self
{
$this->replyBroadcast = $replyBroadcast;
$this->broadcastReply = $broadcastReply;

return $this;
}
Expand All @@ -289,7 +289,7 @@ public function toArray(): array
'metadata' => $this->metaData?->toArray(),
'mrkdwn' => $this->mrkdwn,
'thread_ts' => $this->threadTs,
'reply_broadcast' => $this->replyBroadcast,
'reply_broadcast' => $this->broadcastReply,
'unfurl_links' => $this->unfurlLinks,
'unfurl_media' => $this->unfurlMedia,
'username' => $this->username,
Expand Down
2 changes: 1 addition & 1 deletion tests/Slack/Feature/SlackMessageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ public function it_can_send_threaded_reply_as_broadcast_reference(): void
{
$this->sendNotification(function (SlackMessage $message) {
$message->text('See https://api.slack.com/methods/chat.postMessage for more information.');
$message->replyBroadcast(true);
$message->broadcastReply(true);
})->assertNotificationSent([
'channel' => '#ghost-talk',
'text' => 'See https://api.slack.com/methods/chat.postMessage for more information.',
Expand Down

0 comments on commit af28f42

Please sign in to comment.