mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
API Remove references to non-existent installation tool (#11274)
This commit is contained in:
parent
8179047af5
commit
be6ca2a91d
@ -27,7 +27,6 @@ use SilverStripe\View\SSViewer;
|
|||||||
use SilverStripe\View\ThemeManifest;
|
use SilverStripe\View\ThemeManifest;
|
||||||
use SilverStripe\View\ThemeResourceLoader;
|
use SilverStripe\View\ThemeResourceLoader;
|
||||||
use Exception;
|
use Exception;
|
||||||
use SilverStripe\Dev\Deprecation;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simple Kernel container
|
* Simple Kernel container
|
||||||
@ -305,31 +304,6 @@ abstract class BaseKernel implements Kernel
|
|||||||
throw new HTTPResponse_Exception($response);
|
throw new HTTPResponse_Exception($response);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* If missing configuration, redirect to install.php if it exists.
|
|
||||||
* Otherwise show a server error to the user.
|
|
||||||
*
|
|
||||||
* @deprecated 5.3.0 Will be removed without equivalent functionality
|
|
||||||
*
|
|
||||||
* @param string $msg Optional message to show to the user on an installed project (install.php missing).
|
|
||||||
*/
|
|
||||||
protected function redirectToInstaller($msg = '')
|
|
||||||
{
|
|
||||||
Deprecation::notice('5.3.0', 'Will be removed without equivalent functionality');
|
|
||||||
// Error if installer not available
|
|
||||||
if (!file_exists(Director::publicFolder() . '/install.php')) {
|
|
||||||
throw new HTTPResponse_Exception(
|
|
||||||
$msg,
|
|
||||||
500
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Redirect to installer
|
|
||||||
$response = new HTTPResponse();
|
|
||||||
$response->redirect(Director::absoluteURL('install.php'));
|
|
||||||
throw new HTTPResponse_Exception($response);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return ManifestCacheFactory
|
* @return ManifestCacheFactory
|
||||||
*/
|
*/
|
||||||
|
@ -7,7 +7,6 @@ use SilverStripe\Dev\Install\DatabaseAdapterRegistry;
|
|||||||
use SilverStripe\ORM\DB;
|
use SilverStripe\ORM\DB;
|
||||||
use Exception;
|
use Exception;
|
||||||
use LogicException;
|
use LogicException;
|
||||||
use SilverStripe\Dev\Deprecation;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Simple Kernel container
|
* Simple Kernel container
|
||||||
@ -48,12 +47,12 @@ class CoreKernel extends BaseKernel
|
|||||||
protected function validateDatabase()
|
protected function validateDatabase()
|
||||||
{
|
{
|
||||||
$databaseConfig = DB::getConfig();
|
$databaseConfig = DB::getConfig();
|
||||||
// Gracefully fail if no DB is configured
|
// Fail if no DB is configured
|
||||||
if (empty($databaseConfig['database'])) {
|
if (empty($databaseConfig['database'])) {
|
||||||
$msg = 'Silverstripe Framework requires a "database" key in DB::getConfig(). ' .
|
$msg = 'Silverstripe Framework requires a "database" key in DB::getConfig(). ' .
|
||||||
'Did you forget to set SS_DATABASE_NAME or SS_DATABASE_CHOOSE_NAME in your environment?';
|
'Did you forget to set SS_DATABASE_NAME or SS_DATABASE_CHOOSE_NAME in your environment?';
|
||||||
$this->detectLegacyEnvironment();
|
$this->detectLegacyEnvironment();
|
||||||
Deprecation::withNoReplacement(fn() => $this->redirectToInstaller($msg));
|
throw new HTTPResponse_Exception($msg, 500);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -18,8 +18,6 @@
|
|||||||
"public-files-installed": [
|
"public-files-installed": [
|
||||||
".htaccess",
|
".htaccess",
|
||||||
"index.php",
|
"index.php",
|
||||||
"install-frameworkmissing.html",
|
|
||||||
"install.php",
|
|
||||||
"web.config"
|
"web.config"
|
||||||
],
|
],
|
||||||
"resources-dir": "customised-resources-dir"
|
"resources-dir": "customised-resources-dir"
|
||||||
|
@ -18,8 +18,6 @@
|
|||||||
"public-files-installed": [
|
"public-files-installed": [
|
||||||
".htaccess",
|
".htaccess",
|
||||||
"index.php",
|
"index.php",
|
||||||
"install-frameworkmissing.html",
|
|
||||||
"install.php",
|
|
||||||
"web.config"
|
"web.config"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user