Trim quotes from frankenphp app path to ensure valid directory check

This commit is contained in:
crazywhalecc 2026-02-27 09:52:02 +08:00
parent 28c82b811b
commit f9fe2adb1d
No known key found for this signature in database
GPG Key ID: 1F4BDD59391F2680

View File

@ -140,6 +140,7 @@ trait frankenphp
$frankenphpAppPath = $package->getBuildOption('with-frankenphp-app');
if ($frankenphpAppPath) {
$frankenphpAppPath = trim($frankenphpAppPath, "\"'");
if (!is_dir($frankenphpAppPath)) {
throw new WrongUsageException("The path provided to --with-frankenphp-app is not a valid directory: {$frankenphpAppPath}");
}