diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ee32dc..8d81ebd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ ## [Unreleased] +### Changed + +- Requires `innmind/immutable:~5.16` +- Requires `innmind/graphviz:~4.0` + ### Fixed - PHP `8.4` deprecations diff --git a/README.md b/README.md index 23d8ed0..08e373f 100644 --- a/README.md +++ b/README.md @@ -40,9 +40,11 @@ Factory::build() Render::of()($trace) ), ) + ->unwrap() ->wait(); ``` -**Note**: the svg rendered contains links to the files where call frames and exceptions occured, you can change the link by providing an instance of [`Link`](src/Link.php) to the `Render` object. +> [!NOTE] +> The svg rendered contains links to the files where call frames and exceptions occured, you can change the link by providing an instance of [`Link`](src/Link.php) to the `Render` object. Example of a rendered stack trace: ![](graph.svg) diff --git a/composer.json b/composer.json index 6edc564..1d13663 100644 --- a/composer.json +++ b/composer.json @@ -16,9 +16,9 @@ }, "require": { "php": "~8.2", - "innmind/immutable": "~4.1|~5.0", - "innmind/url": "~4.0", - "innmind/graphviz": "~3.1" + "innmind/immutable": "~5.16", + "innmind/url": "~4.4", + "innmind/graphviz": "~4.0" }, "autoload": { "psr-4": { diff --git a/src/Render.php b/src/Render.php index 17dc157..b9763c2 100644 --- a/src/Render.php +++ b/src/Render.php @@ -287,9 +287,12 @@ private function linkSource( /** * Remove special characters and escape backslashes + * + * @return non-empty-string */ private function clean(string $name): string { + /** @var non-empty-string */ return Str::of($name) ->replace("\x00", '') // remove the invisible character used in the name of anonymous classes ->replace('\\', '\\\\')