mirror of
https://github.com/laravel/valet.git
synced 2026-02-06 08:40:09 +01:00
Drop exits, fix 404 path
This commit is contained in:
@@ -43,7 +43,7 @@ public static function domainFromSiteName(string $siteName): string
|
||||
public static function show404()
|
||||
{
|
||||
http_response_code(404);
|
||||
require __DIR__.'/cli/templates/404.html';
|
||||
require __DIR__.'/../../cli/templates/404.html';
|
||||
exit;
|
||||
}
|
||||
|
||||
|
||||
@@ -68,12 +68,9 @@
|
||||
$isPhpFile = pathinfo($uri, PATHINFO_EXTENSION) === 'php';
|
||||
|
||||
if ($uri !== '/' && ! $isPhpFile && $staticFilePath = $valetDriver->isStaticFile($valetSitePath, $siteName, $uri)) {
|
||||
exit('is static');
|
||||
return $valetDriver->serveStaticFile($staticFilePath, $valetSitePath, $siteName, $uri);
|
||||
}
|
||||
|
||||
exit('is not static');
|
||||
|
||||
/**
|
||||
* Allow for drivers to take pre-loading actions (e.g. setting server variables).
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user