Merge pull request #335 from creative-commoners/pulls/4/upgrade-cms5

DEP PHP Support in CMS5
This commit is contained in:
Maxime Rainville 2023-01-17 10:21:10 +13:00 committed by GitHub
commit fc415c33dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 13 additions and 16 deletions

View File

@ -17,4 +17,4 @@ jobs:
with:
extra_jobs: |
- name_suffix: subsites
composer_require_extra: silverstripe/subsites:^2
composer_require_extra: silverstripe/subsites:^3

View File

@ -1,5 +0,0 @@
<?php
use SilverStripe\Dev\Deprecation;
Deprecation::notification_version('3.0', 'silverstripe/fulltextsearch');

View File

@ -21,19 +21,19 @@
}
],
"require": {
"php": "^7.4 || ^8.0",
"silverstripe/framework": "^4.10",
"monolog/monolog": "~1.15",
"php": "^8.1",
"silverstripe/framework": "^5",
"monolog/monolog": "^3.2",
"silverstripe/solr-php-client": "^1.0",
"symfony/process": "^3.4 || ^4",
"tractorcow/silverstripe-proxy-db": "^1",
"symfony/process": "^6.2",
"silverstripe/silverstripe-proxy-db": "^2",
"ext-curl": "*"
},
"require-dev": {
"silverstripe/cms": "^4.0",
"silverstripe/cms": "^5",
"phpunit/phpunit": "^9.5",
"squizlabs/php_codesniffer": "^3.0",
"symbiote/silverstripe-queuedjobs": "^4.9"
"squizlabs/php_codesniffer": "^3",
"symbiote/silverstripe-queuedjobs": "^5"
},
"autoload": {
"psr-4": {

View File

@ -3,6 +3,7 @@
namespace SilverStripe\FullTextSearch\Utils\Logging;
use Monolog\Handler\AbstractProcessingHandler;
use Monolog\LogRecord;
use Monolog\Logger;
use Symbiote\QueuedJobs\Services\QueuedJob;
@ -53,7 +54,7 @@ class QueuedJobLogHandler extends AbstractProcessingHandler
return $this->queuedJob;
}
protected function write(array $record)
protected function write(LogRecord $record): void
{
// Write formatted message
$this->getQueuedJob()->addMessage($record['formatted']);

View File

@ -3,6 +3,7 @@
namespace SilverStripe\FullTextSearch\Tests\SolrReindexTest;
use Monolog\Handler\AbstractProcessingHandler;
use Monolog\LogRecord;
use SilverStripe\Dev\TestOnly;
/**
@ -32,7 +33,7 @@ class SolrReindexTest_Handler extends AbstractProcessingHandler implements TestO
$this->messages = array();
}
protected function write(array $record)
protected function write(LogRecord $record): void
{
$this->messages[] = $record['message'];
}