Skip to content
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

Do not escape forwardslashes on slack #1397

Closed
wants to merge 5 commits into from
Closed

Do not escape forwardslashes on slack #1397

wants to merge 5 commits into from

Conversation

alies-dev
Copy link
Contributor

@alies-dev alies-dev commented Nov 9, 2019

closes #1396

Goals:

  • don't escape slashes in Slack messages to make them more readable (\Monolog\Utils::jsonEncode do it by default)

Side-effects:

  • cleanup: remove code to support old PHP versions
  • improve tests to reuse vars from setUp() method

alies-dev and others added 5 commits November 9, 2019 13:44
Use whitespace in returned data to format it. Available as of PHP 5.4.0.

@see https://www.php.net/manual/en/json.constants.php#constant.json-pretty-print
1. it's optional in JSON
2. the main purpose of json encoding for slack it to stringify some types. So, perception is the king, not compatibility (actually we don't need to care about compatibility of JSON format at all)
@Seldaek Seldaek closed this in ec3e0e3 Nov 13, 2019
@alies-dev alies-dev deleted the do-not-escape-forwardslashes-on-slack branch November 13, 2019 10:48
@lyrixx lyrixx mentioned this pull request Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unneeded character escaping for Slack/SlackRecord
2 participants