Skip to content

Commit

Permalink
Merge pull request #4 from tgalopin/logger
Browse files Browse the repository at this point in the history
Add logging feature
  • Loading branch information
tgalopin authored Nov 28, 2018
2 parents e7c214d + 4dc70b0 commit fe9c3d1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"require": {
"php": ">=7.1",
"symfony/framework-bundle": "^3.4|^4.0",
"tgalopin/html-sanitizer": "^1.0"
"tgalopin/html-sanitizer": "^1.1"
},
"require-dev": {
"phpunit/phpunit": "^7.4",
Expand Down
7 changes: 6 additions & 1 deletion src/Resources/config/services.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,12 @@
<services>
<defaults public="false" />

<service id="html_sanitizer.builder" class="HtmlSanitizer\SanitizerBuilder" />
<service id="html_sanitizer.builder" class="HtmlSanitizer\SanitizerBuilder">
<call method="setLogger">
<argument type="service" id="logger" on-invalid="null" />
</call>
<tag name="monolog.logger" channel="html-sanitizer" />
</service>

<service id="html_sanitizer.extension.basic" class="HtmlSanitizer\Extension\Basic\BasicExtension">
<tag name="html_sanitizer.extension" />
Expand Down

0 comments on commit fe9c3d1

Please sign in to comment.