Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ This project adheres to [Semantic Versioning](https://semver.org/).
### Removed

### Fixed
- Make the exception codes 32-bit safe (#287)
- Remove associated subscriptions when a subscriber list or subscriber is removed (#271, #272)
- Always truncate the DB tables after an integration test (#259)
- Adapt the system tests to possible HTTP errors (#256)
Expand Down
15 changes: 7 additions & 8 deletions src/Composer/ModuleFinder.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ private function validateBundlesSectionInExtra(array $extra)
if (!is_array($extra['phplist/core']['bundles'])) {
throw new \InvalidArgumentException(
'The extras.phplist/core.bundles section in the composer.json must be an array.',
1505411665146
1505411665
);
}

Expand All @@ -90,9 +90,8 @@ private function validateBundlesSectionInExtra(array $extra)
foreach ($bundleExtras as $key => $bundleName) {
if (!is_string($bundleName)) {
throw new \InvalidArgumentException(
'The extras.phplist/core.bundles. ' . $key .
'" section in the composer.json must be a string.',
1505412184038
'The extras.phplist/core.bundles. ' . $key . '" section in the composer.json must be a string.',
1505412184
);
}
}
Expand All @@ -112,7 +111,7 @@ private function validatePhpListSectionInExtra(array $extra)
if (!is_array($extra['phplist/core'])) {
throw new \InvalidArgumentException(
'The extras.phplist/core" section in the composer.json must be an array.',
1505411436144
1505411436
);
}
}
Expand Down Expand Up @@ -183,7 +182,7 @@ private function validateRoutesSectionInExtra(array $extra)
if (!is_array($extra['phplist/core']['routes'])) {
throw new \InvalidArgumentException(
'The extras.phplist/core.routes section in the composer.json must be an array.',
1506429004462
1506429004
);
}

Expand All @@ -194,7 +193,7 @@ private function validateRoutesSectionInExtra(array $extra)
throw new \InvalidArgumentException(
'The extras.phplist/core.routes. ' . $routeName .
'" section in the composer.json must be an array.',
1506429860740
1506429860
);
}
}
Expand Down Expand Up @@ -260,7 +259,7 @@ private function validateGeneralConfigurationSectionInExtra(array $extra)
if (!is_array($extra['phplist/core']['configuration'])) {
throw new \InvalidArgumentException(
'The extras.phplist/core.configuration section in the composer.json must be an array.',
1508165934174
1508165934
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/Composer/ScriptHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ private static function preventScriptFromCorePackage(Event $event)
if ($packageName === static::CORE_PACKAGE_NAME) {
throw new \DomainException(
'This Composer script must not be called for the core package itself.',
1501240572934
1501240572
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/Core/ApplicationKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ private function readBundleConfiguration(): array
{
$configurationFilePath = $this->getApplicationDir() . '/Configuration/bundles.yml';
if (!is_readable($configurationFilePath)) {
throw new \RuntimeException('The file "' . $configurationFilePath . '" could not be read.', 1504272377302);
throw new \RuntimeException('The file "' . $configurationFilePath . '" could not be read.', 1504272377);
}

return Yaml::parse(file_get_contents($configurationFilePath));
Expand Down
2 changes: 1 addition & 1 deletion src/Core/ApplicationStructure.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function getApplicationRoot(): string
if (!file_exists($applicationRoot . '/composer.json')) {
throw new \RuntimeException(
'There is no composer.json in the supposed application root "' . $applicationRoot . '".',
1501169001588
1501169001
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Core/Bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ public function configure(): Bootstrap
private function assertConfigureHasBeenCalled()
{
if (!$this->isConfigured) {
throw new \RuntimeException('Please call configure() first.', 1501170550897);
throw new \RuntimeException('Please call configure() first.', 1501170550);
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/Core/Environment.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public static function validateEnvironment(string $environment)
$environmentsText = '"' . implode('", ', static::$validEnvironments) . '"';
throw new \UnexpectedValueException(
'$environment must be one of ' . $environmentsText . ', but actually was: "' . $environment . '"',
1499112172108
1499112172
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/Routing/ExtraLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct(ApplicationStructure $applicationStructure)
public function load($resource, $type = null): RouteCollection
{
if ($this->loaded) {
throw new \RuntimeException('Do not add the "extra" loader twice.', 1500587713150);
throw new \RuntimeException('Do not add the "extra" loader twice.', 1500587713);
}

$routes = new RouteCollection();
Expand Down
8 changes: 4 additions & 4 deletions src/TestingSupport/Traits/SymfonyServerTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ trait SymfonyServerTrait
protected function startSymfonyServer(string $environment)
{
if (!\in_array($environment, static::$validEnvironments, true)) {
throw new \InvalidArgumentException('"' . $environment . '" is not a valid environment.', 1516284149961);
throw new \InvalidArgumentException('"' . $environment . '" is not a valid environment.', 1516284149);
}
if ($this->lockFileExists()) {
throw new \RuntimeException(
Expand Down Expand Up @@ -187,18 +187,18 @@ protected function getApplicationRoot(): string
private function checkDocumentRoot(string $documentRoot)
{
if (!\file_exists($documentRoot)) {
throw new \RuntimeException('The document root "' . $documentRoot . '" does not exist.', 1499513246550);
throw new \RuntimeException('The document root "' . $documentRoot . '" does not exist.', 1499513246);
}
if (!\is_dir($documentRoot)) {
throw new \RuntimeException(
'The document root "' . $documentRoot . '" exists, but is no directory.',
1499513263757
1499513263
);
}
if (!\is_readable($documentRoot)) {
throw new \RuntimeException(
'The document root "' . $documentRoot . '" exists and is a directory, but is not readable.',
1499513279590
1499513279
);
}
}
Expand Down