Skip to content

Commit

Permalink
Merge pull request #12 from wow-apps/3.2.13
Browse files Browse the repository at this point in the history
3.2.13 (view CHANGELOG.md)
  • Loading branch information
wow-apps committed Dec 21, 2018
2 parents 91bc2f3 + 0f7e053 commit 904d3ab
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 16 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Expand Up @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [3.2.13] - 2018-12-21
### Changed
- Fixed characters replacement for links in trait ([Issue #11](https://github.com/wow-apps/symfony-slack-bot/issues/11))

## [3.2.12] - 2018-10-09
### Changed
- Fixed setting of message icon ([Issue #9](https://github.com/wow-apps/symfony-slack-bot/issues/9))
Expand Down
3 changes: 2 additions & 1 deletion Command/WowappsSlackbotTestCommand.php
Expand Up @@ -120,6 +120,7 @@ private function drawConfig(SymfonyStyle $symfonyStyle, array $slackBotConfig)

/**
* @return bool
* @throws \ReflectionException
*/
private function sendTestMessage()
{
Expand All @@ -146,7 +147,7 @@ private function sendTestMessage()
->setShowQuote(true)
->setQuoteType(SlackBot::QUOTE_SUCCESS)
->setQuoteText($this->inlineMultilines($quoteText))
->setQuoteTitle('SlackBot for Symfony 3')
->setQuoteTitle('SlackBot for Symfony')
->setQuoteTitleLink('https://github.com/wow-apps/symfony-slack-bot')
;

Expand Down
12 changes: 4 additions & 8 deletions README.md
Expand Up @@ -87,18 +87,13 @@ To test your configuration, send test message by next command:
![Test command result preview](http://cdn.wow-apps.pro/slackbot/slackbot_preview-v2.jpg)


# Documentation

* [Home](https://github.com/wow-apps/symfony-slack-bot/wiki)
* [Installation](https://github.com/wow-apps/symfony-slack-bot/wiki/1.-Installation)
* [Using SlackBot](https://github.com/wow-apps/symfony-slack-bot/wiki/2.-Using-SlackBot)
* [Additional helpers](https://github.com/wow-apps/symfony-slack-bot/wiki/3.-Additional-helpers)
# [Documentation](https://wow-apps.github.io/symfony-slack-bot/docs/#/)

# News and updates:
# News and updates

Follow news and updates in my Telegram channel [@wow_apps_pro](https://t.me/wow_apps_pro) or Twitter [@alexey_samara_](https://twitter.com/alexey_samara_)

# Say thanks:
# Say thanks

I don't ask for donates, I do what I do for free, for all development community. But I will be grateful if you inform me on the email in which project you are using this Bundle, as well as I will be glad to criticize and suggestions.

Expand Down Expand Up @@ -133,6 +128,7 @@ Do you want to make a change? Pull requests are welcome.
* [3.1.0] Missing phpDocs

## Changed
* [3.2.13] Fixed characters replacement for links in trait ([Issue #11](https://github.com/wow-apps/symfony-slack-bot/issues/11))
* [3.2.12] Fixed setting of message icon ([Issue #9](https://github.com/wow-apps/symfony-slack-bot/issues/9))
* [3.2.12] Functions `setIcon` and `getIcon` for SlackBot DTO set as deprecated and will be removed in version 3.3 ([Issue #9](https://github.com/wow-apps/symfony-slack-bot/issues/9))
* [3.2.12] Test command now send message with random emoji as icon
Expand Down
2 changes: 0 additions & 2 deletions Tests/Traits/SlackMessageTraitTest.php
Expand Up @@ -148,8 +148,6 @@ public function testEscapeCharacters()
{
$expect = $testString = $this->randomString() . '<&>';
$expect = str_replace('&', '&amp;', $expect);
$expect = str_replace('<', '&lt;', $expect);
$expect = str_replace('>', '&gt;', $expect);
$actual = $this->escapeCharacters($testString);

$this->assertEquals($expect, $actual);
Expand Down
7 changes: 2 additions & 5 deletions Traits/SlackMessageTrait.php
Expand Up @@ -137,14 +137,11 @@ public function formatLink(string $title, string $url): string
/**
* @param string $string
* @return string
* @deprecated
* @see https://github.com/wow-apps/symfony-slack-bot/wiki/3.-Additional-helpers#escape-special-characters
*/
public function escapeCharacters(string $string): string
{
$string = str_replace('&', '&amp;', $string);
$string = str_replace('<', '&lt;', $string);
$string = str_replace('>', '&gt;', $string);

return $string;
return str_replace('&', '&amp;', $string);
}
}

0 comments on commit 904d3ab

Please sign in to comment.