diff --git a/app/Fixers/LaravelBladeFixer.php b/app/Fixers/LaravelBladeFixer.php index 2ad56d79..1c0b7697 100644 --- a/app/Fixers/LaravelBladeFixer.php +++ b/app/Fixers/LaravelBladeFixer.php @@ -65,7 +65,13 @@ protected function applyFix(SplFileInfo $file, Tokens $tokens): void $result = app(Prettier::class)->run([$path]); if ($result->failed()) { - throw new PrettierException($result->errorOutput()); + $error = $result->errorOutput(); + + if (str($error)->startsWith('[error]') && str($error)->contains('SyntaxError:')) { + $error = str($error)->after('SyntaxError: ')->before("\n")->value(); + } + + throw new PrettierException($error); } $tokens->setCode($result->output()); diff --git a/builds/pint b/builds/pint index 00f8fbba..5e3c7bd0 100755 Binary files a/builds/pint and b/builds/pint differ