Skip to content

Commit 07d7096

Browse files
authored
INT-286: Add support for Magento 2.4.9 and PHP 8.4
Add support for Magento 2.4.9 and PHP 8.4
1 parent 5404253 commit 07d7096

12 files changed

Lines changed: 21 additions & 17 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
runs-on: ubuntu-latest
99
strategy:
1010
matrix:
11-
php: ['8.3']
11+
php: ['8.4']
1212
deps: ['stable']
1313

1414
steps:

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Changelog
22
## Unreleased
3+
### Add
4+
- Add support for Magento v2.4.9
5+
- Add support for PHP 8.4
6+
37
### Update
48
- Update WebComponents library to version 5.1.7
59
- Add template to suggest element

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
}
1111
],
1212
"require": {
13-
"php": "~8.1.0||~8.2.0||~8.3.0",
13+
"php": "~8.1.0||~8.2.0||~8.3.0||~8.4.0",
1414
"omikron/factfinder-communication-sdk": "^0.9.9",
1515
"magento/framework": "^103.0.7",
1616
"magento/module-catalog": "^104.0.7",
@@ -25,7 +25,7 @@
2525
"require-dev": {
2626
"pdepend/pdepend": "^2.16",
2727
"phpmd/phpmd" : "^2.15",
28-
"phpunit/phpunit": "~9.5.0",
28+
"phpunit/phpunit": "^9.6",
2929
"magento/magento-coding-standard": "*",
3030
"friendsofphp/php-cs-fixer": "^3.58"
3131
},

src/Console/Command/Export.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ protected function configure(): void
5656
/**
5757
* {@inheritdoc}
5858
*/
59-
protected function execute(InputInterface $input, OutputInterface $output)
59+
protected function execute(InputInterface $input, OutputInterface $output): int
6060
{
6161
$this->state->setAreaCode('frontend');
6262
$storeIds = $this->getStoreIds((int) $input->getOption('store'));

src/Exception/ExportPreviewValidationException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
class ExportPreviewValidationException extends \Exception
1010
{
11-
public function __construct($message = '', $code = 0, Throwable $previous = null)
11+
public function __construct($message = '', $code = 0, ?Throwable $previous = null)
1212
{
1313
parent::__construct(sprintf('Product will not be exported. Reason: %s', $message), $code, $previous);
1414
}

src/Exception/ResponseException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
class ResponseException extends \RuntimeException
88
{
9-
public function __construct(string $message = '', int $code = 0, \Throwable $previous = null) // phpcs:ignore
9+
public function __construct(string $message = '', int $code = 0, ?\Throwable $previous = null) // phpcs:ignore
1010
{
1111
parent::__construct($message ?: 'Response body was empty', $code, $previous);
1212
}

src/Model/Adminhtml/System/Config/Backend/Feed/Frequency.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ public function __construct(
2828
ScopeConfigInterface $config,
2929
TypeListInterface $cacheTypeList,
3030
WriterInterface $configWriter,
31-
AbstractResource $resource = null,
32-
AbstractDb $resourceCollection = null,
31+
?AbstractResource $resource = null,
32+
?AbstractDb $resourceCollection = null,
3333
array $data = []
3434
) {
3535
parent::__construct($context, $registry, $config, $cacheTypeList, $resource, $resourceCollection, $data);

src/Model/Api/CredentialsFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public function __construct(ObjectManagerInterface $objectManager, AuthConfig $a
1919
$this->authConfig = $authConfig;
2020
}
2121

22-
public function create(array $authData = null)
22+
public function create(?array $authData = null)
2323
{
2424
return $this->objectManager->create(Credentials::class, $authData ??
2525
[

src/Model/Config/CmsConfig.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public function __construct(ScopeConfigInterface $scopeConfig)
1717
$this->scopeConfig = $scopeConfig;
1818
}
1919

20-
public function getCmsBlacklist(int $scopeCode = null): array
20+
public function getCmsBlacklist(?int $scopeCode = null): array
2121
{
2222
$pages = (string) $this->scopeConfig->getValue(self::PATH_DISABLE_CMS_PAGES, 'store', $scopeCode);
2323
return array_filter(explode(',', $pages));

src/Model/Config/CommunicationConfig.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public function __construct(ScopeConfigInterface $scopeConfig, UrlInterface $url
3131
$this->urlBuilder = $urlBuilder;
3232
}
3333

34-
public function getChannel(int $scopeId = null): string
34+
public function getChannel(?int $scopeId = null): string
3535
{
3636
return (string) $this->scopeConfig->getValue(self::PATH_CHANNEL, ScopeInterface::SCOPE_STORES, $scopeId);
3737
}
@@ -41,12 +41,12 @@ public function getAddress(): string
4141
return (string) $this->scopeConfig->getValue(self::PATH_ADDRESS, ScopeInterface::SCOPE_STORES);
4242
}
4343

44-
public function isChannelEnabled(int $scopeId = null): bool
44+
public function isChannelEnabled(?int $scopeId = null): bool
4545
{
4646
return $this->scopeConfig->isSetFlag(self::PATH_IS_ENABLED, ScopeInterface::SCOPE_STORES, $scopeId);
4747
}
4848

49-
public function isPushImportEnabled(int $scopeId = null): bool
49+
public function isPushImportEnabled(?int $scopeId = null): bool
5050
{
5151
return $this->scopeConfig->isSetFlag(self::PATH_DATA_TRANSFER_IMPORT, ScopeInterface::SCOPE_STORES, $scopeId);
5252
}

0 commit comments

Comments
 (0)