mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
DEP Upgrade installer dependencies (#10534)
This commit is contained in:
parent
919cfcf435
commit
3601b7ab8b
@ -24,15 +24,15 @@
|
||||
"require": {
|
||||
"php": "^8.1",
|
||||
"bramus/monolog-colored-line-formatter": "^2.0.3",
|
||||
"composer/installers": "^2.1.1",
|
||||
"guzzlehttp/guzzle": "^7.4.5",
|
||||
"composer/installers": "^2.2",
|
||||
"guzzlehttp/guzzle": "^7.5.0",
|
||||
"guzzlehttp/psr7": "^2.4.0",
|
||||
"embed/embed": "^4.4.4",
|
||||
"league/csv": "^9.8.0",
|
||||
"m1/env": "^2.2.0",
|
||||
"monolog/monolog": "^1.27.1",
|
||||
"nikic/php-parser": "^4.14.0",
|
||||
"psr/container": "^1.1.2",
|
||||
"monolog/monolog": "^3.2.0",
|
||||
"nikic/php-parser": "^4.15.0",
|
||||
"psr/container": "^2.0",
|
||||
"silverstripe/config": "^2",
|
||||
"silverstripe/assets": "^2",
|
||||
"silverstripe/vendor-plugin": "^2",
|
||||
@ -100,8 +100,6 @@
|
||||
]
|
||||
},
|
||||
"include-path": [
|
||||
"src/",
|
||||
"src/includes/",
|
||||
"thirdparty/"
|
||||
],
|
||||
"scripts": {
|
||||
|
@ -874,10 +874,8 @@ class Injector implements ContainerInterface
|
||||
*
|
||||
* Will recursively call itself for each depth of dotting.
|
||||
*
|
||||
* @param string $name
|
||||
* @return boolean
|
||||
*/
|
||||
public function has($name)
|
||||
public function has(string $name): bool
|
||||
{
|
||||
return (bool)$this->getServiceName($name);
|
||||
}
|
||||
|
@ -7,6 +7,7 @@ use SilverStripe\Dev\Debug;
|
||||
use SilverStripe\Control\Director;
|
||||
use SilverStripe\Control\Email\Email;
|
||||
use Monolog\Formatter\FormatterInterface;
|
||||
use Monolog\LogRecord;
|
||||
|
||||
/**
|
||||
* Produce a friendly error message
|
||||
@ -101,7 +102,7 @@ class DebugViewFriendlyErrorFormatter implements FormatterInterface
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function format(array $record)
|
||||
public function format(array|LogRecord $record)
|
||||
{
|
||||
// Get error code
|
||||
$code = empty($record['code']) ? $this->getStatusCode() : $record['code'];
|
||||
|
@ -4,6 +4,7 @@ namespace SilverStripe\Logging;
|
||||
|
||||
use SilverStripe\Dev\Debug;
|
||||
use Monolog\Formatter\FormatterInterface;
|
||||
use Monolog\LogRecord;
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
@ -11,7 +12,7 @@ use Exception;
|
||||
*/
|
||||
class DetailedErrorFormatter implements FormatterInterface
|
||||
{
|
||||
public function format(array $record)
|
||||
public function format(array|LogRecord $record)
|
||||
{
|
||||
if (isset($record['context']['exception'])) {
|
||||
/** @var Exception $exception */
|
||||
|
@ -4,6 +4,7 @@ namespace SilverStripe\Logging;
|
||||
|
||||
use Monolog\Formatter\FormatterInterface;
|
||||
use Monolog\Handler\AbstractProcessingHandler;
|
||||
use Monolog\LogRecord;
|
||||
use SilverStripe\Control\Controller;
|
||||
use SilverStripe\Control\Director;
|
||||
use SilverStripe\Control\HTTPResponse;
|
||||
@ -106,7 +107,7 @@ class HTTPOutputHandler extends AbstractProcessingHandler
|
||||
*
|
||||
* @return FormatterInterface
|
||||
*/
|
||||
public function getFormatter()
|
||||
public function getFormatter(): FormatterInterface
|
||||
{
|
||||
if (Director::is_cli() && ($cliFormatter = $this->getCLIFormatter())) {
|
||||
return $cliFormatter;
|
||||
@ -120,7 +121,7 @@ class HTTPOutputHandler extends AbstractProcessingHandler
|
||||
*
|
||||
* @return FormatterInterface
|
||||
*/
|
||||
public function getDefaultFormatter()
|
||||
public function getDefaultFormatter(): FormatterInterface
|
||||
{
|
||||
return parent::getFormatter();
|
||||
}
|
||||
@ -141,7 +142,7 @@ class HTTPOutputHandler extends AbstractProcessingHandler
|
||||
* @param array $record
|
||||
* @return bool
|
||||
*/
|
||||
protected function write(array $record)
|
||||
protected function write(LogRecord $record): void
|
||||
{
|
||||
ini_set('display_errors', 0);
|
||||
|
||||
@ -164,7 +165,5 @@ class HTTPOutputHandler extends AbstractProcessingHandler
|
||||
|
||||
$response->setBody($record['formatted']);
|
||||
$response->output();
|
||||
|
||||
return false === $this->getBubble();
|
||||
}
|
||||
}
|
||||
|
@ -3,6 +3,7 @@
|
||||
namespace SilverStripe\Logging;
|
||||
|
||||
use Monolog\Handler\AbstractProcessingHandler;
|
||||
use Monolog\LogRecord;
|
||||
|
||||
/**
|
||||
* Echo the output as preformatted HTML, emulating console output in a browser.
|
||||
@ -17,10 +18,7 @@ use Monolog\Handler\AbstractProcessingHandler;
|
||||
class PreformattedEchoHandler extends AbstractProcessingHandler
|
||||
{
|
||||
|
||||
/**
|
||||
* @param array $record
|
||||
*/
|
||||
protected function write(array $record)
|
||||
protected function write(LogRecord $record): void
|
||||
{
|
||||
echo sprintf('<pre>%s</pre>', htmlspecialchars($record['formatted'], ENT_QUOTES, 'UTF-8'));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user