mirror of
https://github.com/laravel/valet.git
synced 2026-02-06 08:40:09 +01:00
use local valet driver as name
This commit is contained in:
@@ -43,11 +43,11 @@ abstract public function frontControllerPath($sitePath, $siteName, $uri);
|
|||||||
public static function assign($sitePath, $siteName, $uri)
|
public static function assign($sitePath, $siteName, $uri)
|
||||||
{
|
{
|
||||||
$drivers = [];
|
$drivers = [];
|
||||||
|
|
||||||
if ($customSiteDriver = static::customSiteDriver($sitePath)) {
|
if ($customSiteDriver = static::customSiteDriver($sitePath)) {
|
||||||
$drivers[] = $customSiteDriver;
|
$drivers[] = $customSiteDriver;
|
||||||
}
|
}
|
||||||
|
|
||||||
$drivers = array_merge($drivers, static::driversIn(VALET_HOME_PATH.'/Drivers'));
|
$drivers = array_merge($drivers, static::driversIn(VALET_HOME_PATH.'/Drivers'));
|
||||||
|
|
||||||
$drivers[] = 'LaravelValetDriver';
|
$drivers[] = 'LaravelValetDriver';
|
||||||
@@ -78,7 +78,7 @@ public static function assign($sitePath, $siteName, $uri)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the custom driver class from the site path, if one exists.
|
* Get the custom driver class from the site path, if one exists.
|
||||||
*
|
*
|
||||||
@@ -87,13 +87,13 @@ public static function assign($sitePath, $siteName, $uri)
|
|||||||
*/
|
*/
|
||||||
public static function customSiteDriver($sitePath)
|
public static function customSiteDriver($sitePath)
|
||||||
{
|
{
|
||||||
if (! file_exists($sitePath.'/SiteValetDriver.php')) {
|
if (! file_exists($sitePath.'/LocalValetDriver.php')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
require_once $sitePath.'/SiteValetDriver.php';
|
require_once $sitePath.'/LocalValetDriver.php';
|
||||||
|
|
||||||
return 'SiteValetDriver';
|
return 'LocalValetDriver';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user