Skip to content

Commit

Permalink
Fix removing of json options, fixes Seldaek#1469
Browse files Browse the repository at this point in the history
  • Loading branch information
Seldaek committed Jul 8, 2020
1 parent 71c124b commit 0ae6fd8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Monolog/Formatter/NormalizerFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public function setJsonPrettyPrint(bool $enable): self
if ($enable) {
$this->jsonEncodeOptions |= JSON_PRETTY_PRINT;
} else {
$this->jsonEncodeOptions ^= JSON_PRETTY_PRINT;
$this->jsonEncodeOptions &= ~JSON_PRETTY_PRINT;
}

return $this;
Expand Down Expand Up @@ -255,6 +255,6 @@ public function addJsonEncodeOption($option)

public function removeJsonEncodeOption($option)
{
$this->jsonEncodeOptions ^= $option;
$this->jsonEncodeOptions &= ~$option;
}
}

0 comments on commit 0ae6fd8

Please sign in to comment.