8000 [Notifier] Add SlackOptions::threadTs() to send message as reply by WaylandAce · Pull Request #40992 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Notifier] Add SlackOptions::threadTs() to send message as reply #40992

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
[Notifier] Add SlackOptions::threadTs() to send message as reply
  • Loading branch information
WaylandAce authored and nicolas-grekas committed May 6, 2021
commit d3807a79b806f280730d565cce24c2e90b2836b6
1 change: 1 addition & 0 deletions src/Symfony/Component/Notifier/Bridge/Slack/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ CHANGELOG
* Check for maximum number of buttons in Slack action block
* Add HeaderBlock
* Slack access tokens needs to start with "xox" (see https://api.slack.com/authentication/token-types)
* Add `SlackOptions::threadTs()` to send message as reply

5.2.0
-----
Expand Down
10 changes: 10 additions & 0 deletions src/Symfony/Component/Notifier/Bridge/Slack/SlackOptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -181,4 +181,14 @@ public function username(string $username): self

return $this;
}

/**
* @return $this
*/
public function threadTs(string $threadTs): self
{
$this->options['thread_ts'] = $threadTs;

return $this;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ public function toArraySimpleOptionsProvider(): iterable
yield [['unfurl_links' => true]];
yield [['unfurl_media' => true]];
yield [['username' => 'baz']];
yield [['thread_ts' => '1503435956.000247']];
}

/**
Expand Down Expand Up @@ -111,6 +112,7 @@ public function setProvider(): iterable
yield ['unfurlLinks', 'unfurl_links', true];
yield ['unfurlMedia', 'unfurl_media', true];
yield ['username', 'username', 'baz'];
yield ['threadTs', 'thread_ts', '1503435956.000247'];
}

public function testSetBlock()
Expand Down
0