Skip to content

Commit b80938d

Browse files
authored
bug fix formatter when JSON include html tags
1 parent 5c7ce53 commit b80938d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/TelegramFormatter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ private function getMessageForException($exception)
145145
}
146146

147147
$message .= PHP_EOL . '<b>Request Inputs:</b> <pre>' . str_replace(
148-
["\n", " "], ['',''], json_encode($request->except('password', 'password_confirmation'), JSON_UNESCAPED_UNICODE)
148+
["\n", " ", '<' , '>'], ['', '' , '&lt;', '&gt;'], json_encode($request->except('password', 'password_confirmation'), JSON_UNESCAPED_UNICODE)
149149
) . '</pre>';
150150

151151
$message .= PHP_EOL . PHP_EOL . '<b>Trace: </b> ' . PHP_EOL . '<b> => </b> => ' . substr($exception->getTraceAsString(), 0, 1000) . ' ...';

0 commit comments

Comments
 (0)